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

Comment on


This works on *nix:

use strict ; use warnings ; my $timeout_in = 5 ; eval { local $SIG{ALRM} = sub { die "timed_out\n" }; alarm($timeout_in); while(<>) { alarm($timeout_in); my $in = $_ ; chomp( $in ) ; print $in . "\n" ; last if( $in eq 'exit' ); } alarm(0) ; }; if ($@) { die( "Hey ... whats with the slow typing ??\n" ); }

In reply to Re^5: how to use angle operator with timeout? by tmharish
in thread how to use angle operator with timeout? by Mark_Galeck

and:  <code> code here </code>

  • Please read these before you post! —
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Log In?

    What's my password?
    Create A New User
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others wandering the Monastery: (13)
    As of 2013-12-20 21:45 GMT
    Find Nodes?
      Voting Booth?

      How do you parse XML?

      Results (433 votes), past polls