- or download this
my $index = 0;
my @array;
$array[0] = "hello";
$array[1] = "world";
print "$names[0] $names[1]"; #=> "hello world"
- or download this
my $index = 0;
my %hash;
$hash{greeting} = "hello";
$hash{name} = "world";
print "$hash{greeting} $hash{name}"; #=> "hello world"
- or download this
my $key = "greeting";
$hash{$key} = "hello";