in reply to Re^2: Opinion: where Perl5 wasn't attractive for me
in thread Opinion: where Perl5 wasn't attractive for me
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.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Opinion: where Perl5 wasn't attractive for me
by rsFalse (Chaplain) on Nov 20, 2014 at 13:01 UTC |