Suffixation of decimal numbers: Difference between revisions

Content added Content deleted
Line 1,052: Line 1,052:
{{works with|cpython|3.7.3}}
{{works with|cpython|3.7.3}}
Tested in Python 3.7.3<br />
Tested in Python 3.7.3<br />
Chose 3 places after decimal (where applicable) as default rounding precision. Number to suffize taken as a string.
Chose 3 places after decimal (where applicable) as default rounding precision. Number to suffize taken as a string. There are some edge cases where this fails due to binary arithmetic differing from decimal arithmetic and things not rounding nicely.
<lang python>
<lang python>
import math
import math