[tpm] chomp problem

Uri Guttman uri at StemSystems.com
Mon Feb 7 10:28:10 PST 2011

>>>>> "OG" == Omid Gulban <omid.gulban at sickkids.ca> writes:

  OG> I expected a 1 second delay in between the print statements. BUT PERL waits 8 (1 second for a,b,c,d...h)  seconds and prints everything together!
  OG> maybe I should uninstall perl and reinstall it again!

  OG> I have used chomp for about 8 years and never seen this.

it has nothing to do with chomp. you are printing partial lines so they
are buffered in stdout don't get flushed right away. either print the
lines with a newline or set $| to force flushing with every print.


Uri Guttman  ------  uri at stemsystems.com  --------  http://www.sysarch.com --
-----  Perl Code Review , Architecture, Development, Training, Support ------
---------  Gourmet Hot Cocoa Mix  ----  http://bestfriendscocoa.com ---------

More information about the toronto-pm mailing list