You can either use a for loop:
my @arr; for (my $i=0; $i<100; $i++) { $arr[$i]=1}
or the x operator:
my @arr = (1)x100;
In reply to Re: Filling an array
by jryan
in thread Filling an array
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |