Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re^4: Hard syntax error or disambiguable parsing?

by ikegami (Patriarch)
on Jan 29, 2009 at 13:40 UTC ( [id://739900]=note: print w/replies, xml ) Need Help??


in reply to Re^3: Hard syntax error or disambiguable parsing?
in thread Hard syntax error or disambiguable parsing?

Did I miss something here?

You probably think the ".." in "for[each] $i ( 0 .. 5 )" is the range operator and that it creates a list of 6 elements. It's not, and no list of 6 elements is created.

perlsyn distinguishes between For Loops ("C"-style For Loops) and Foreach Loops (List Iteration Loops), but "for[each] $i ( 0 .. 5 )" is neither. It's actually a Counting Loop like FOR ... NEXT in BASIC.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (3)
As of 2026-01-19 05:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What's your view on AI coding assistants?





    Results (122 votes). Check out past polls.

    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.