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.
Good question. I was following other kata which divide the random tests into two groups: small tests, which print the test input to help the user with debugging, and large tests which don't. The large tests could be removed, but maybe it's fun to see the size of the trees.
In terms of changing the range, random.randint(10, 100000) is not the size of the tree; it's the minimax value of the tree. So making it 10000 - 100000 wouldn't make a difference.
Done!
Lua has
Int64
s, unsure if we have them on CW or not but if we do at least switch to those.Why was this approved, default Lua numbers are not precise as integers above
2**53 - 1
due to beingdouble
s under the hood. Source (official Lua documentation).Approved.
Approved by someone
fixed