Javascript curriculum unresponsive

After completing the Basic Javascript all other javascript sections have bugs in the exercise to the point where you cannot submit answers (correct or not) to complete the exercise.

Anyone else have this issue. Is there a way to fix this?

Reloading the page usually fixes problems of this nature. Is there a specific challenge causing this issue? What browser are you using?

I’ve tried reloading, to no avail. Even tried signing out and signing back in later and trying again. No luck. My browser is chrome. There are a lot of exercises that don’t work in ES6, a few in Regular Expressions at the end, two at the end of Basic Data Structures. That’s so far.

What do you mean that they don’t work? That the tests don’t pass regardless of what you try or that the tests are stuck at running tests written in the console?

Can you post an example of a challenge and the code you were using to solve it?

1 Like

The challenge is “ES6: Use the Rest Operator with Function Parameters.”

Wants me to “Modify the function ‘sum’ so that it uses the rest operator and it works in the same way with any number of parameters.”

original code is this:

const sum = (function() {
“use strict”;
return function sum(x, y, z) {
const args = [ x, y, z ];
return args.reduce((a, b) => a + b, 0);
};
})();
console.log(sum(1, 2, 3)); // 6

After working on it and doing some research I did this:

const sum = (function() {
“use strict”;
return function sum(…z) {
return z.reduce((a,b) => a+b, 0);
};
})();
console.log(sum(1, 2, 3)); // 6

It tells me “The sum function uses the … spread operator on the args parameter.” When run the test.

Well, you are using it on the z parameter… try actually using the rest operator with the args parameter

Well, that was much appreciated :upside_down_face::blush: Can I ask you about another or just make a new topic?

You can try asking here - usually it is recommended one challenge per topic but if it is just a question of tests interpretation…