Search for "floating point numbers" on SO and you'll get a slew of answers as to why this happens. It has to do with how floating point numbers are represented in computers.
How is floating point stored? When does it matter?
Another article on the matter - Floating Point Approximation