On Fri, 22 Jun 2001, Martijn van Exel wrote: > Why the $! does > > (int($cnt/2) == ($cnt/2)) > > not return TRUE for an even $cnt and FALSE for an odd $cnt ? Use the modulus operator %. It returns a remainder of a division -- in the case of modulus 2, it will return either 0 or 1. -- Brett http://www.chapelperilous.net/btfwk/ ------------------------------------------------------------------------ "I don't care who does the electing as long as I get to do the nominating." -- Boss Tweed
- Checking for odd/even Martijn van Exel
- Re: Checking for odd/even paladin
- Re: Checking for odd/even Brett W. McCoy
- Re: Checking for odd/even Martijn van Exel
- Re: Checking for odd/even Brett W. McCoy
- Re: Checking for odd/even Nigel Wetters
- Re: Checking for odd/even Nigel Wetters