Thursday 9 April 2020

How to pad zeroes to a string?

Strings:
>>> n = '4'
>>> print(n.zfill(3))
004

from : https://stackoverflow.com/questions/339007/how-to-pad-zeroes-to-a-string

No comments:

Post a Comment