Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: 0 illegal modulus?

by Vynce (Friar)
on Jun 11, 2001 at 07:11 UTC ( #87398=note: print w/ replies, xml ) Need Help??


in reply to 0 illegal modulus?

well, you could override the modulus operator if you prefer, and use an idiom like

$ans = ($y*1) ? $x % $y : 0;
see overload for details.

.


Comment on Re: 0 illegal modulus?
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://87398]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (6)
As of 2014-07-30 02:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (229 votes), past polls