프로그래밍/Algorithm

백준 2869번(python)-달팽이는 올라가고 싶다

dev_youngduck 2020. 11. 4. 21:07
728x90

반올림,올림,내림

올림,내림은 math모듈 가져와야함

 

import math

n=4.234

올림:math.ceil(n)

      5

내림:math.floor(n)

      4

반올림:round(n,2)

         4.23

 

반응형