Last active
March 12, 2020 17:01
-
-
Save ashour/f8ae851d17ae8a55b2cad9c5a6ef0069 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from babel.numbers import format_decimal | |
value = 123456.78 | |
print(format_decimal(value, locale='en_US')) # => 123,456.78 (American format) | |
print(format_decimal(value, locale='fr_FR')) # => 123 456,78 (French format) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment