Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Re: 0 illegal modulus?

by Vynce (Friar)
on Jun 15, 2001 at 13:33 UTC ( [id://88732]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    bash-2.04$ perl -e 'print 5 % foo'
    Illegal modulus zero at -e line 1.
    
  2. or download this
    bash-2.04$ perl -e '$x = 5; $y = "foo"; print ($y ? $x % $y : $x); pri
    +nt "\n"'
    Illegal modulus zero at -e line 1.
    ...
    0
    bash-2.04$ perl -e '$x = 5; $y = "foo"; print (($y*1) ? $x % $y : $x);
    + print "\n"'
    5
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (3)
As of 2024-04-24 13:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found