DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR PYTHON
how to prefix numbers with zero in python
print(f"{n:02}") #wherein, if n is a single digit, it will be prefixed with one 0
PREVIOUS
NEXT
Tagged:
#prefix
#numbers
#python
ADD COMMENT
Topic
COMMENT
Name
1+1 =
Submit