iOS 向下取整、向上取整、四舍五入
向上取整:float ceilf(float); double ceil(double);
向下取整:float floorf(float); double floor(double);
四舍五入:float roundf(float); double round(double);
截尾取整函数:trunc(x)
向上取整:float ceilf(float); double ceil(double);
向下取整:float floorf(float); double floor(double);
四舍五入:float roundf(float); double round(double);
截尾取整函数:trunc(x)
本文标题:iOS 向下取整、向上取整、四舍五入
本文链接:https://www.haomeiwen.com/subject/boisixtx.html
网友评论