U
usenet
It is often possible to declare and assign a variable in a single
statement, such as:
my $foo = 'bar';
or
my @foo = qw{bar baz};
Is it possible to do this in a single statement (under strict):
my %character_value;
@character_value{'a'..'z'} = (1..26);
Thanks!
statement, such as:
my $foo = 'bar';
or
my @foo = qw{bar baz};
Is it possible to do this in a single statement (under strict):
my %character_value;
@character_value{'a'..'z'} = (1..26);
Thanks!