Perl_Love has asked for the wisdom of the Perl Monks concerning the following question:
I want print 1..10, but it print 1,1,1,1,1,1,1,1,1,1 thanks a lot!#!/usr/bin/perl -w use Parallel::ForkManager; my $pm = Parallel::ForkManager->new(5); my @num = 1 .. 10; my $ok=0; for my $num (@num) { $pm->start and next; ++$ok; print "$ok\n"; $pm->finish; } $pm->wait_all_children;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Help, Parallel::ForkManager
by Anonymous Monk on Jul 29, 2016 at 03:55 UTC |