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 mutated the input array
try to use print at some points in the routine to see if the program is doing what you are expecting it do
Even though 3 comes after the frist 5, 7 comes before the 2nd 5. Hence, 3,7 as a pair comes earlier.
Two of the excruciatingly long tests seem to be broken. Debug code:
puts "Initial ints length is: #{ints.length}"
if ints.length < 10
puts ints
end
shows that the "Two Million Numbers With Pair At End: Should terminate with a valid pair output" and "Two Million Numbers With Pair At Start: Should terminate with a valid pair output" tests are only passing in 2 and 1 element arrays respectively, but are expecting a match (that isn't present in the arrays).