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

Im looking for threading / forking methods for running through a Array of variables, as in Printing each, each thread. I'm trying to find which is faster for a program i need to make. im quite new to perl and only dealt with forking lists. i tried playing with thread::queue but no avail, Example scripts would be suggested. Thank you monks.

Replies are listed 'Best First'.
Re: Threading / Forking Examples Needed
by BrowserUk (Patriarch) on Mar 20, 2014 at 05:39 UTC
    Im looking for threading / forking methods for running through a Array of variables, as in Printing each, each thread.

    Your description makes no sense (to me at least), so it'd be hard to produce an example.

    If you're familiar with fork why not post your forking solution and we can try and reproduce it with threads.


    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.
Re: Threading / Forking Examples Needed
by Anonymous Monk on Mar 20, 2014 at 14:25 UTC

    Just *starting* a single thread will likely cost you more time than printing an entire array.

    What are you really doing?