DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR PYTHON
python round float to 2 decimals
value = 5.34343 rounded_value = round(value, 2) # 5.34
Source by stackoverflow.com #
PREVIOUS
NEXT
Tagged:
#python
#float
#decimals
ADD COMMENT
Topic
COMMENT
Name
1+4 =
Submit