summaryrefslogtreecommitdiff
path: root/Base/home/anon/js/array.js
blob: b62f262396bfd010f1e8f4fa864615ae1b8e1ffd (plain)
1
2
3
4
5
6
7
8
9
10
11
var a = [1, 2, 3];

a[1] = 5;

var push_result = a.push(7);

for (var i = 0; i < a.length; ++i) {
    console.log(a[i]);
}

console.log("push result: " + push_result);