Assigning to variables in a condition and then checking the result of the assignment is not a great idea!  :-)