Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Using loops inside an 'if' statement

by thinker (Parson)
on Oct 02, 2003 at 09:36 UTC ( #295868=note: print w/ replies, xml ) Need Help??


in reply to Using loops inside an 'if' statement

Hi jonnyfolk,

There is nothing wrong with putting a while in an if statement. The problem you have is a syntax error. Change

while (<FILE)> { to while (<FILE>) {

Notice the order of the brackets

Hope this helps

thinker


Comment on Re: Using loops inside an 'if' statement
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (17)
As of 2014-12-18 14:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (55 votes), past polls