parseInt("数字字符串",基数)、parseFlout()
toString(16):如果是数字字符串,则转为16进制返回
parseInt("10"); //返回 10
parseInt("19",10); //返回 19 (10+9)
parseInt("11",2); //返回 3 (2+1)
parseInt("17",8); //返回 15 (8+7)
parseInt("1f",16); //返回 31 (16+15)
parseInt("010"); //未定:返回 10 或 8
- floor()、ceil() :向上向下取整
Math.abs()
获取绝对值Math.random()
取[0,1)的随机小数Math.max() and Max.min()
获取一组数据中的最大值和最小值- Math.pow()获取一个值的多少次幂 、Math.sqrt()对数值开方
Math.round()
四舍五入