Just another Perl shrine | |
PerlMonks |
Re^3: Opinion: where Perl5 wasn't attractive for meby roboticus (Chancellor) |
on Nov 20, 2014 at 12:38 UTC ( [id://1107917]=note: print w/replies, xml ) | Need Help?? |
Rather than $num = ($x - $x % $y) / $y, why not use $num = int $x / $y? I agree that having to use the former would be a bit troublesome. When you mentioned integer division in the OP, I couldn't figure out exactly what was so troublesome about using int. Seeing this, I'm thinking that maybe you're just not aware of it. Update: I forgot to mention, perl has the sqrt function. ...roboticus When your only tool is a hammer, all problems look like your thumb.
In Section
Meditations
|
|