thanks, my mistake
5 * 5 * 5 = 125 and 1^3+2^3+3^3+4^3 = 100 so, the expected result is ok, the tests are consistent.
5 * 5 * 5 = 125
1^3+2^3+3^3+4^3 = 100
How come in the description this function is expected to return 100 when passed (0,4):
cubeSum(0,4); // => 1^3+2^3+3^3+4^3 = 100;
... but when tested to return 225 (only 5^3) when passed (0,5)?
Test.assertEquals(cubeSum(5, 0), 225, "cubeSum(5,0)");
I'm either getting it wrong or the task is inconsistent with the test :) Thanks!
Loading collection data...
thanks, my mistake
5 * 5 * 5 = 125
and1^3+2^3+3^3+4^3 = 100
so, the expected result is ok, the tests are consistent.How come in the description this function is expected to return 100 when passed (0,4):
... but when tested to return 225 (only 5^3) when passed (0,5)?
I'm either getting it wrong or the task is inconsistent with the test :) Thanks!