function mixedNumbers(arr) {
// change code below this line
arr.push("I", 2, "three");
arr.unshift(7, "VIII", 9);
// change code above this line
return arr;
}
// do not change code below this line
console.log(mixedNumbers(['IV', 5, 'six']));
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.181 Safari/537.36.
function mixedNumbers(arr) {
// change code below this line
arr.unshift("three");
arr.unshift(2);
arr.unshift("I");
arr.push(7);
arr.push("VIII");
arr.push(9);
// change code above this line
return arr;
}
// do not change code below this line
console.log(mixedNumbers(['IV', 5, 'six']));
I feel like my code should have passed the test. It uses push() and unshift(), but it uses them with spread operators, which is more readable than multiple lines, at least to me. It passes the output test but doesn’t seem to realize that the required functions were used.