常规除法: /
> 82/10 [1] 8.2
整除: %/%
> 82%/%10 [1] 8
求余: %%
> 82%%10 [1] 2
向下取整 floor()
> floor(8.9) [1] 8
向上取整 ceiling()
> ceiling(8.1) [1] 9
四舍五入取整 round()
> round(8.4) [1] 8 > round(8.5) [1] 8 > round(8.6) [1] 9
参考:https://zhidao.baidu.com/question/1770571969202268220.html