JS单体内置对象:global和Math
1、内置对象
概念:不必显式地实例化内置对象.
如:object Array String
global math
2、global、window对象
(1)、URL编码方法
encodeURI()和encodeURIComponent():可以对URI进行编码
decodeURI()和decodeURIComponent():解码所有的字符
3、math
(1)、min()和 max()
作用:返回数组中的最大值和最小值
(2)、Math.ceil() 、Math.floor()、 Math.round()、Math.random()
近期评论