Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Reaped: Perl Loops

by NodeReaper (Curate)
on Jul 01, 2013 at 00:32 UTC ( #1041678=perlquestion: print w/replies, xml ) Need Help??

NodeReaper has asked for the wisdom of the Perl Monks concerning the following question:

This node falls below the community's threshold of quality. You may see it by logging in.

Replies are listed 'Best First'.
Re: Perl Loops
by kcott (Archbishop) on Jul 01, 2013 at 01:05 UTC

    G'day stamp1982,

    You asked this yesterday: Perl Loops

    You were provided with substantial help including actual code and links to relevant documentation.

    You appear to have made little or no effort to either read the documentation or attempt any coding yourself.

    This is your homework. You should do it yourself. You'll learn nothing if someone else does it for you.

    Please try to do this yourself. If you get stuck, show code that you have written along with any output (including errors messages) and ask a specific question about whatever problem you have encountered.

    -- Ken

      Dear Ken, Thanks for your input but I just updated my post to reflect where I needed the correction/help at. Thanks!

        Not shown as an Update in your OP:

        I am getting syntax error at near ");" at while (0). How do you fix it?

        To be honest, I find your reply quite unbelievable. Four monks responded to your post yesterday: davido (in Re: Perl Loops) answered the very question you're now asking; vinoth.ree (in Re: Perl Loops) showed a code example of how to do it; farang (in Re: Perl Loops) and rjt (in Re: Perl Loops) pointed you to documentation for this loop construct.

        Go back and read the advice, code and documentation provided. Then make some effort yourself!

        Also read "How do I change/delete my post?".

        Update: Added the names of the four monks and links to their specific posts.

        -- Ken

Re: Perl Loops
by NetWallah (Canon) on Jul 01, 2013 at 01:39 UTC
    The syntax for 'while' is:
    while (EXPR) BLOCK
    Your code 'while(0);' is missing the 'BLOCK'. It can be fixed (syntactically) by adding an empty block:
    while(0){};

                 My goal ... to kill off the slow brain cells that are holding me back from synergizing my knowledge of vertically integrated mobile platforms in local cloud-based content management system datafication.

Re: Perl Loops
by Anonymous Monk on Jul 01, 2013 at 00:38 UTC

    How can I get this to work for this:

    1) you try 2) you try again 3) try some more 4) repeat

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (1)
As of 2022-07-03 16:52 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?