Python2 3中的 math.floor

Python3(https://docs.python.org/3/library/math.html#math.floor):

math.floor(x)

Return the floor of x, the largest integer less than or equal to x. If x is not a float, delegates to x.__floor__(), which should return an Integral value.

 

Python2(https://docs.python.org/2/library/math.html#math.floor):

math.floor(x)

Return the floor of x as a float, the largest integer value less than or equal to x.

posted @ 2018-10-18 10:57  Misakikure  阅读(806)  评论(0编辑  收藏  举报