Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Question about defined loop

by ssandv (Hermit)
on Mar 11, 2010 at 17:13 UTC ( [id://828098]=note: print w/replies, xml ) Need Help??


in reply to Question about defined loop

defined is not a loop, it is a function. That may sound pedantic, but it's difficult to help people who use words wrong, because it's hard to understand them.

One of many ways to do what (I *think*) you want would be to make the last line
return defined($not_exposed_reason)?$self->{_not_exposed_reason}:"No e +xposed reason";
which uses the ? : construct (sometimes called the ternary conditional operator) to produce the value before the : if the condition before the ? is true, and the one after the : if the condition is false. I'm not entirely sure how helpful that is, because your question is pretty hard to parse.

Replies are listed 'Best First'.
Re^2: Question about defined loop
by siddheshsawant (Sexton) on Mar 11, 2010 at 17:59 UTC
    Thanks a lot dude!!!!!Thats helped out .....
    A reply falls below the community's threshold of quality. You may see it by logging in.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (8)
As of 2024-04-24 12:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found