A good opportunity to implement a hashtable: lots of collisions without it.
A re-post of Solution 1137054, because that one doesn't appear in the list of solutions, for some reason (I'm not sure why).
Find the stride of the longest skip sequence
108 Solvers
Flag largest magnitude swings as they occur
592 Solvers
211 Solvers
6180 Solvers
296 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!