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

Does anyone use OptiPerl as a tool? I cannot run this basic program on it without an error message and then a connection time out.
while (<>) { chomp; print join("\t", (split /:/)[0, 2, 1, 5] ), "\n"; }

Help me oh monastic mentors.

JK

Replies are listed 'Best First'.
Re: Optiperl as a tool (more info needed)
by shmem (Chancellor) on Sep 05, 2008 at 20:31 UTC
    I cannot run this basic program on it without an error message

    You had better posted that message. In what environment are you trying to run that snippet?

      without an error message means there was no error message :)

        No, if the OP "can't without", it means he "can with", so there's an error message, isn't there?

Re: Optiperl as a tool
by jdrago_999 (Hermit) on Sep 06, 2008 at 19:15 UTC
    Optiperl continually executes your code to notify you of syntax errors. I thought it ran it under perl -c.

    Apparently it is getting hung up on the while (<>) part.