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.
Thanks a lot!
Thanks a lot!
Swift version has available deprecated API only, using modern documentation it's almost impossible to be sure what API is unusable and what is valid. Please update to Swift 5. Thank you
Very old and deprecated Swift API, unable to complete kata with modern Swift documentation. Updating kata to Swift 5 would be very great.
The problem is with big numbers(was in my case, probably in yours as well). Try to run your solution with 9223372036854775807. In my case I used Int variable and it just ran outside of available values, changing it to UInt helped, though it's just a quick fix.
I don't know why the compiler doesn't show this error on Codewars, in Xcode it is shown properly.
When submitting wrong solution in Swift, inner implementation of checks uses deprecated API, which crashes.