Replaced shift() with unshift() in description
parent
2a7432ef5d
commit
fca35c32d5
|
@ -117,7 +117,7 @@
|
|||
"<blockquote>let twentyThree = 'XXIII';<br>let romanNumerals = ['XXI', 'XXII'];<br><br>romanNumerals.unshift('XIX', 'XX');<br>// now equals ['XIX', 'XX', 'XXI', 'XXII']<br><br>romanNumerals.push(twentyThree);<br>// now equals ['XIX', 'XX', 'XXI', 'XXII', 'XXIII']",
|
||||
"Notice that we can also pass variables, which allows us even greater flexibility in dynamically modifying our array's data.",
|
||||
"<hr>",
|
||||
"We have defined a function, <code>mixedNumbers</code>, which we are passing an array as an argument. Modify the function by using <code>push()</code> and <code>shift()</code> to add <code>'I', 2, 'three'</code>, to the beginning of the array and <code>7, 'VIII', '9'</code> to the end so that the returned array contains representations of the numbers 1-9 in order."
|
||||
"We have defined a function, <code>mixedNumbers</code>, which we are passing an array as an argument. Modify the function by using <code>push()</code> and <code>unshift()</code> to add <code>'I', 2, 'three'</code> to the beginning of the array and <code>7, 'VIII', '9'</code> to the end so that the returned array contains representations of the numbers 1-9 in order."
|
||||
],
|
||||
"challengeSeed": [
|
||||
"function mixedNumbers(arr) {",
|
||||
|
|
Loading…
Reference in New Issue