Javascript Math ceil()、floor()、round()三个函数的区别
摘要:
Round是四舍五入的。。。Ceiling是向上取整。。float是向下取整下面来介绍将小数值舍入为整数的几个方法:Math.ceil()、Math.floor()和Math.round()。 这三个方法分别遵循下列舍入规则:◎Math.ceil()执行向上舍入,即它总是将数值向上舍入为最接近的整数... 阅读全文
posted @ 2015-07-03 19:28 huo2song 阅读(247) 评论(0) 推荐(0)
浙公网安备 33010602011771号