in reply to Re^4: if (defined @arr) problem
in thread if (defined @arr) problem
- remove all of the elements of the array
- replace all of the elements with the value undef
That could be @a = (undef) x scalar @a
So yes , saying "undef an array" i meant undef @a . I do think it's what the OP was meaning to do when trying to affect one single undef value to the whole array . This really sounds like undef @array.
Now about delete for the moment i never got to use it, neither did i use exist . I gather it's because they are used mainly with objects, are they ?
Regards,
secret
In Section
Seekers of Perl Wisdom