http://www.perlmonks.org?node_id=11102562

CougarXR7 has asked for the wisdom of the Perl Monks concerning the following question:

Hope I did not offend anyone earlier. I do not know much about perl, I could tell you my story but I do not want to take up your forum.

I am trying access the elements in an array.

When the program starts it load from a file, ciphers.

# load the list with ciphers from the config file if no ciphers were detected.
$self->load_ciphers() unless $self->check_cipher_count(); $self->{game} = undef;

supportedgames.pl

our %S = (%S, game => { "jetfighter4" => {key => "M3pL73", label => "JetFighter + IV: Fortress America"}, "projectigi2r" => {key => "j4F9cY", label => "IGI2: Covert S +trike", port => 26001}, }, ); 1;
When I do this, $self->check_cipher_count(); the count is 2 not 7

I cannot get perl to print anything concerning that array. Always errors, always!

#print Dumper $rx->{game}->1->{label};

#print Dumper $self->{game}->1->{label};

#print Dumper $rx->{game}->[0]->{cipher};

It's like the Perl code does not know that jetfighter4 is JetFighter IV is jetfighter4

Hope someone can help me learn how to access an array in perl!

Thanks!