in reply to Fair schedule allocation?
use strict; use warnings; my $aa = 2192; my @volunteers = (('Ben') x 5, ('Scott') x 4, 'Jim'); for (0..98){ my $bb = $aa + 200; my $name = $volunteers[ $_ % @volunteers ]; print "$aa-$bb\t\t$name", "\n"; $aa+=201; }
As a side note -- $a and $b are special variables, don't assign these names to your variables.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Fair schedule allocation?
by oko1 (Deacon) on Jan 05, 2010 at 03:16 UTC |