This comment is hidden because it contains spoiler information about the solution
Test cases was fixed a year ago.
@clarity thank you alot i didnt read the last line omg
From the description: The questions array is already defined for you and is not the same as the one in the example. Drop the questions array and it will pass.
The questions array is already defined for you and is not the same as the one in the example.
It looks like someone edited the description to something very similar to what you posted.
In my opinion
-1 for i
-1 for forEach rather than map ( the behavior of map is more verbose than modifying an object and expecting it to be modifed in the original array )
however, i am sure the forEach is more performant, if only marginally.
If you pass 0.5 to the function, it won't return the negative value;
I disabled adblock and I was able to submit.
I passed all tests but I can't submit