Is there any way to get the name of a variable by knowing its memory
address?
Thanks,
Zach
Thanks for all the responses guys. I have rewritten my code with defined,
and that appears to be exactly was I was looking for.
Thanks,
Zach
>
> > way to test
> > these values so that only undef will return as false?
> >
> > Thanks,
> > Zach
> >
>
Is there a way to test for values where zero is valid?
For instance:
%a_Hash;
$a_hash{"user_id"} = 0;
$a_hash{"user_name"} = "root" if ($a_hash{"user_id"});
print $a_hash{"user_id"} if ($a_hash{"user_id"});
print $a_hash{"user_name"} if ($a_hash{"user_name"});
Sometimes the user_id can be undef