No I did not mean to say I was finding this way as slow . But It has
happened so many times before that there have been better ways to do
things which I have been doing and many of them were so commonplace
that I am suprised they didnt occur to me .
So I just wanted to make sure I was not go
On Thu, 28 Nov 2002, Ramprasad A Padmanabhan wrote:
> Which is the quickest way of converting an array to hash keys
>
> I have an array
> @ARRAY = qw ( a b c d e );
>
> # Convert array to hash keys , so can easily check for exists
> # The values of the hash are immaterial to me
>
> @HASH{@ARRAY
Ramprasad A Padmanabhan said:
> Which is the quickest way of converting an array to hash keys
>
> I have an array
> @ARRAY = qw ( a b c d e );
>
> # Convert array to hash keys , so can easily check for exists
> # The values of the hash are immaterial to me
>
> @HASH{@ARRAY}=@ARRAY;
>
>
>
Which is the quickest way of converting an array to hash keys
I have an array
@ARRAY = qw ( a b c d e );
# Convert array to hash keys , so can easily check for exists
# The values of the hash are immaterial to me
@HASH{@ARRAY}=@ARRAY;
foreach (@SOME_OTHER_ARRAY) {
next if(exists($HAS