arrayOfObjects.forEach((element) => element.runLab(), () => {
if (element.runLab !== 1) {
console.log(element.runLab());
}
})
arrayOfObjects.forEach((element) => {
const resultLab = element.runLab();
if (resultLab !== 1) {
console.log(resultLab);
}
});
- 1 2 3 4 5 6 7 8 9
1
2 ?
3 ?
4 ?
5
...
items[i].addEventListener('click', function() {alert(i);});
var a = 0;
console.log(a++)
var a = 0;
console.log(++a)