Answers for "python f string space padding"

0

python f string space padding

>>> for n in range(1,11):
...     print(f'The number is {n:4}')
... 
The number is    1
The number is    2
The number is    3
The number is    4
The number is    5
The number is    6
The number is    7
The number is    8
The number is    9
The number is   10
>>>
Posted by: Guest on May-22-2021

Python Answers by Framework

Browse Popular Code Answers by Language