Runden Sie zwei Dezimalstellen Python ab
format(1.4000,'.2f') #to include zeroes while rounding to 2 decimals
Cheerful Caterpillar
format(1.4000,'.2f') #to include zeroes while rounding to 2 decimals
import math
val = 3.14
math.floor(val) # rounds down --> 3
math.ceil(val) # rounds up val --> 4
>>> round(3.9)