add_commas
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
add_commas [2021/01/13 20:47] – [add commas] raju | add_commas [2021/01/13 20:57] (current) – [input is a single number; without pandas] raju | ||
---|---|---|---|
Line 3: | Line 3: | ||
search tags | f strings, thousands separator, format integers with commas | search tags | f strings, thousands separator, format integers with commas | ||
==== input is a single number; without pandas ==== | ==== input is a single number; without pandas ==== | ||
+ | | ' | ||
+ | | f' | ||
+ | |||
< | < | ||
In [1]: | In [1]: | ||
Line 22: | Line 25: | ||
</ | </ | ||
- | Ref:- https:// | + | Examples using a print statement |
+ | < | ||
+ | In [1]: | ||
+ | a = 123456 | ||
+ | |||
+ | In [2]: | ||
+ | print(' | ||
+ | The magic number is = 123,456 | ||
+ | |||
+ | In [3]: | ||
+ | print(' | ||
+ | The magic number is = 123,456 | ||
+ | |||
+ | In [4]: | ||
+ | print(' | ||
+ | The magic number is = 123456 | ||
+ | </ | ||
+ | |||
+ | Ref:- | ||
+ | * https:// | ||
+ | * https:// | ||
==== input is a dataframe ==== | ==== input is a dataframe ==== |
add_commas.1610570820.txt.gz · Last modified: 2021/01/13 20:47 by raju