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 can do floor division using the
//
operator:I didn't know that Code Wars uses 2.7. A lot of the changed parts of Python 3 works in 2.7, so I use 3.
I think it may be that you're using Python 2.7.6. I'm using Python 3.3.2.
You're right about the int() function flooring the number automatically. I've always been under the impression that you could only use int() on a number if it converted exactly. However, I looked at your second suggestion, and it doesn't work for me. I did 3 / 2, and it returned 1.5, not one. I also tried 3 / 1, and I got 3.0. I don't quite get how we're getting different results. Thanks for the help, regardless!