On Thu, Dec 18, 2008 at 19:58, David Alban <exta...@extasia.org> wrote:
> On Thu, Dec 18, 2008 at 10:17 AM, Chris Jack <chris_j...@msn.com> wrote:
>> 4) How many different variable types are there in Perl? Be as sensibly 
>> voluminous in your answer as you are > able.
>>
>>
>>  have been asked this in more interviews that I care to recall and generally 
>> interviewers seem to be looking > for 3 (scalar, list, and hash) but code, 
>> filehandle, and format are also high level types.
>
> i would have said only two:  scalar and list, since arrays and hashes
> are both lists.

They can both be initialised from lists, but I wouldn't call them lists.

That's like saying that '3' is a variable just because it's a literal
that you can use to initialise a variable with.

Lists are values, arrays and hashes are variables.

Cheers,
-- 
Philip Newton <philip.new...@gmail.com>

Reply via email to