Casting boolean to int

Take a look at this thread:

There is a big difference between code that merely works, and is maintainable, readable, easily fixed in the future, etc.