Re: [PHP] Integer division
Hi Todd! if $a = 3.5 then echo (int)$a // print 3 regards Marcelo Gulin Todd Cary escribió: > > What is the syntax for dividing 7 by 2 and getting 3; not 3.5? > > Todd > > -- > Todd Cary > Ariste Software > [EMAIL PROTECTED] > > -- > PHP General Mailing List (http://www.php.net/)
RE: [PHP] Integer division
> What is the syntax for dividing 7 by 2 and getting 3; not 3.5? you can use: $intVar = ((int)( 7 / 2 )); Chris