1

I am using pycharm with ipython enabled in debugger.
How can I get nuumeric literals to be displayed/printed with underscode as a thousands separator.
Instead of this 107010000 I need 107_010_000. Please refer to the screenshot where I marked places I want such formatting to be applied.
I already seen this post: https://intellij-support.jetbrains.com/hc/en-us/community/posts/360004398280-DataGrip-2019-2-1-showing-underscore-for-thousands-separator-in-editor

Update:
And I have seen How to print number with commas as thousands separators?
My question is not how to format numeric literal using python programming language. It is about representation in ipython or pycharm debugger. I need this by default.
For instance if I do this:

a = 1000
print(a)

I want to see:

1_000



enter image description here

IamMashed
  • 1,811
  • 2
  • 21
  • 32
  • 1
    As for inline values, there's no such option in PyCharm, unfortunately. And as for ipython, you could write your own print function or even overwrite the build-in one, but I don't think there's a way to avoid formatting using python. – Andrey Resler Feb 07 '20 at 16:58

0 Answers0