Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Strange interaction between print and the ternary conditional operator

by tybalt89 (Parson)
on Feb 20, 2020 at 03:39 UTC ( #11113225=note: print w/replies, xml ) Need Help??


in reply to Strange interaction between print and the ternary conditional operator

Try

print +(1 ? 'yes' : 'no') . ' bar';

And then read the top of perlfunc

  • Comment on Re: Strange interaction between print and the ternary conditional operator
  • Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (3)
As of 2020-05-27 05:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If programming languages were movie genres, Perl would be:















    Results (152 votes). Check out past polls.

    Notices?