for (const section of document.querySelectorAll('.stall')) {
console.log(section);
}
console.log([...{[Symbol.iterator]() {
let i = 0;
return {next() {
console.log('spread', i);
return {value: i++, done: i > 10};
}};
}}]);
for(const item of {[Symbol.iterator]() {
let i = 0;
return {next() {
console.log('for of', i);
return {value: i++, done: i > 10};
}};
}}) console.log('for body', item);
enter ничего не должен делать
в моем примере можете убрать проверку на char === '-' и отрицательные числа станут недоступны