var items = [
[1, 2],
[3, 4],
[5, 6]
];
console.log(items[0][0]); // 1
console.log(items[0][1]); // 2
console.log(items[1][0]); // 3
console.log(items[1][1]); // 4
console.log(items);
Run code snippet
var sum = 0;
for(var i=0; i< arr1.length; i++) {
sum += arr1[i]*arr2[i];
}
Map<String, String> map = new HashMap<String, String>();
map.put("key", "value");
String value = map.get("key");