in reply to Re^2: Value into array
in thread Value into array
A hash instead of an array could be useful for you:
use strict; use warnings; my %hash = ( N1 => { A => 1, B => 1}, N2 => { A => 1, B => 1}, N3 => { A => 1, B => 1}, N6 => { A => 1, B => 1}, N7 => { A => 1, B => 1}, ); # usage e.g. print $hash{N3}{A}, "\n";
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: Value into array
by ameezys (Acolyte) on Apr 08, 2019 at 07:53 UTC | |
by hdb (Monsignor) on Apr 08, 2019 at 08:30 UTC | |
by Marshall (Canon) on Apr 08, 2019 at 07:57 UTC | |
by ameezys (Acolyte) on Apr 08, 2019 at 08:38 UTC | |
by Marshall (Canon) on Apr 08, 2019 at 09:25 UTC |
In Section
Seekers of Perl Wisdom