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

Re: Problem with sleep command in perl

by bulk88 (Priest)
on Aug 03, 2012 at 15:50 UTC ( #985270=note: print w/ replies, xml ) Need Help??


in reply to Problem with sleep command in perl

You are using buffered stdio. Only when the buffer has a newline will it print to console. Turn on autoflush http://perldoc.perl.org/perlvar.html#$| every print should cause a console print, but this also causes higher cpu and is less efficient.

edit for mistake pointed out by another monk


Comment on Re: Problem with sleep command in perl

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (10)
As of 2014-12-25 00:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

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





    Results (159 votes), past polls