Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!newstop!exodus!stef From: stef@zweig.exodus (Stephane Payrard) Newsgroups: comp.lang.perl Subject: associative arrays ? Message-ID: Date: 18 Oct 90 23:11:32 GMT Sender: news@exodus.Eng.Sun.COM Organization: Sun Microsystems -- Mountain View Lines: 26 Is length() supported when applied to an associative array? Why does it return a value equal to : number of keys + number of values + 1 ? example: % perl -e '%a=(1,2);print length %a;' 3 Why associative arrays are not interpreted in double quotes when in the same context regular arrays? I feel it makes things inconsistent. example % perl -e '%a=(1,2); print "%a\n";@a=(1,2);print "@a";' %a 1 2 Thanks -- Stephane Payrard -- stef@eng.sun.com -- (415) 336 3726 SMI 2550 Garcia Avenue M/S 10-09 Mountain View CA 94043