in reply to how to solve producer consumer problem in perl when threads are disabled

The simplest mechanism is a shell pipe.

Producer: perl -e"$|++;for(1..10){ printf qq[%05d\n], $_; sleep 1 }"

Consumer: perl -E"$|++; while(<>){ print; }"

Communications:

>perl -e"$|++;for(1..10){ printf qq[%05d\n], $_; sleep 1 }" | perl -E" +$|++; while(<>){ print; }" 00001 00002 00003 00004 00005 00006 00007 00008 00009 00010

With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.