Skip to content

Commit 9d107a6

Browse files
朱安邦的pro电脑朱安邦的pro电脑
authored andcommitted
Hello
1 parent 7c3ba02 commit 9d107a6

2 files changed

Lines changed: 5 additions & 3 deletions

File tree

test-file.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,9 @@
2121

2222
<script>
2323

24-
24+
console.log(2>100);//false
25+
console.log("2">"100");//true
26+
console.log(123<"124");//true
2527

2628

2729

研究Array类/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,9 +102,9 @@
102102
- concat 将两个数组进行拼接,原有数组不变,例如ary1.concat(ary2)
103103
- ary1.concat() 相当于clice(0)也是克隆数组
104104
- join 将数组按照指定的分隔符拆分字符串,原有的数组不变
105-
- soString 将数组转化为字符串,原有的数组不变
105+
- toString 将数组转化为字符串,原有的数组不变
106106
- sort 数组排序的方法,原有数组改变,我们通常这样写,ary.sort(function(a,b){return a-b;});来实现数组的升序排列
107-
- revser 将数组倒过来排序,原来数组改变
107+
- reverse 将数组倒过来排序,原来数组改变
108108
- indexOf / lastIndexOf 获取数组中某一项的索引,通常用来检测数组中是否包含某一项内容,不包含返回的是-1;这个方法在IE678下不兼容;
109109
- forEach 循环数组中每一项,然后进行相关的操作,这个方法在IE678不兼容,
110110
- ary.forEach(function(item,index,input){},cantext);第二个参数是指定函数中的this,不写默认是window

0 commit comments

Comments
 (0)