QuestenaՎարժանք, որը ցույց է տալիս՝ ինչ կրկնել հաջորդիվ
Հարց 106

Which statements about iterating array.entries() with for...of are true? Select all that apply.

  1. array.entries() immediately returns one array containing every pair
  2. Each yielded item is a two-element index-and-value pairՃիշտ պատասխան
  3. The iterator yields element values without their indexes
  4. Pair destructuring can bind an index and its value during iterationՃիշտ պատասխան

Բացատրություն

The entries iterator yields one two-element array at a time, containing an index and its associated value. Destructuring can bind those two parts during for...of; the method does not itself materialize one large array of every pair.

Շարունակեք այս թեստով

Սկսել վարժանքը
Հարց 106: Which statements about iterating array.entries() with… · JavaScript Fundamentals · Questena