[TOC]
## 1.数组克隆
```
var a = [1,2,3,4]
var b = []
b = b.concat(a) //1
b = a.slice(0) //2
b = [...a] //3
b.push(...a) //4
console.log(b)
```
##2.数组遍历
```
var a = [1,2,3,4]
var b = []
a.forEach(element => {
b.push(element)
});
for (let i in a) {
b.push(a[i])
}
for (let i of a) {
b.push(i)
}
a.map(e=>{
b.push(e)
})
Array.from(a,e=>{
b.push(e)
})
```