Take off the ; from the while loops...

And see if you can turn up the warning level on your compiler. Most modern compilers will say something to the effect of "empty controlled statement -- did you mean the extra semicolon?"
_________________________
-- roger