<script>
function f(){
var s=23.4444;
alert(Math.floor(s)); //只舍不入
alert(Math.ceil(s)); //只入不舍
alert(Math.round(s)); //四舍五入
}
f();
</script>
function f(){
var s=23.4444;
alert(Math.floor(s)); //只舍不入
alert(Math.ceil(s)); //只入不舍
alert(Math.round(s)); //四舍五入
}
f();
</script>
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货