Well, what happens if increment = 2? Or 4? And what would you want to happen? Now in this case it looks like if you start with increment = 3, it will never become 2 or 4, so maybe this is a moot point. Will increment always start at 3, or do you want to code something more general than that?
"I'm not back." - Bill Harding, Twister
Joined: Oct 21, 2000
even if it started at 4 //increment == 4 //4/2 = 2 matches if increment = 2 //increment == 2 //2/2 = 1 matches if increment = 1 //increment == 1 // matches else if increment = 0 as far as i can tell, no matter what value increment starts out at, the else clause will never execute [ April 18, 2004: Message edited by: Randall Twede ]
Joined: Jan 30, 2000
Mmmm, looks like I misread. I was thinking of % for some reason. Looks like you're right. Perhaps the code was refactored from some other form where the else made sense, and then the else was overlooked in the refactoring. It doesn't actually affect anything, so I can imagine it being overlooked.