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.
It should return
new long[0]
. However, your code will not pass large numbers because it will iterate all combinaions ofa
andb
from 0 up ton
.There exists a formula which only requires an O(N) complexity.
That's very kind - thank you!