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.
You're also confusing the test input, console.log comes before the test result, the input you're seeing is of the next test, not from the test you failed.
I got this test failed too. I use console.log to print out the input arrays a and b , I found that this failed test ( a was [1,2,2], b was [2], expected [1] ) is caused by wrong input... The test says b is [2], but exactly b is [] from log.
@kinluek mutating the array you use in a loop is never a good idea, you'll be skipping values like that, it's not a kata issue, it's a problem with your code.
Your solution looks good, especially the comments! Stick with it ^.^
This comment is hidden because it contains spoiler information about the solution
Just saw this. I noticed you have a solution for the kata. Seems like you figured it out ^.^
I also get the same error on the same test, and if I change the sample tests to the one above it checks out.
(EDIT) Our code is wrong - b.length can be shorter than a.length, so it stops by the first iteration
Edit: JS working totally fine for me, and the tests are not flawed in any way. You can post your code here with a spoiler tag if you require some help as most probably your code is doing something wrong.