Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
中文解释:你不能修改测试提供的原始数组。
这个测试的过程应该是:在你的函数运行后,检查原始数组的值是否发生改变。
也就是说:你应该创建一个新的数组(或者复制原数组)来完成接下来的工作。
Your code should not modify/change values from the input array.
So you have to copy the array or find another way that does not change values in the array.
I met the same problem,can U explain it?Thx!
The problem is said in the error message: "You should not modify the input array!" But you did! :-) So the test for checking, that the user-solution does not change the input array, fails correctly!
Hi, I am passing all the tests except this one:
UnchangedArrayTest
✔ Test Passed: Value == '[2, 7, 4, 3, 9]'
✘ You should not modify the input array! - Expected: '[9, 2, 4, 7, 3]', instead got: '[2, 7, 4, 3, 9]'
Not sure why is happening, seems like [2, 7, 4, 3, 9] is the right result that should be expected.
Will appreciate your help!