On Monday, April 29, 2002, at 02:19 , [EMAIL PROTECTED] wrote:
> Hi all - should be simple - but I cannot figure it out > > basically i want to name an array with a subscript ie world0[0] and > world1[0] the 0/1 being a variable, i have tried to > produce a simple example.... do I feel your pain ... it would be neat to have that fly, but it is not at all easy.... > For any help - thanks.. > ---------------------------------------------------------- > @fred = "one,two,three,four"; > > $a=0; > > @array$a=split(/,/, @fred) > > for ($b=0;$b<4;$b++) { > print @array$a[$b]; > } have you thought about using hashes instead? perldoc perldata since what you want is to have arrays of arrays of stuff, rather than trying to skank up variables of variables... eg: my %bigHash = () hence hou would want say $bigHash{'one'} = %hashOfOtherStuff; which gets you towards your idea of $bigHash{$a}->[$b] sort of structure.... ciao drieux --- -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]