Felix - Thanks for the very clear explanation. Dick
Felix Geerinckx wrote: > > on Thu, 18 Apr 2002 12:56:43 GMT, [EMAIL PROTECTED] (Richard Noel Fell) > wrote: > > > However, I do not understand your > > comments about the return value of map. Does not map return a > > reference to an anonymous arrar, not a hash? > > 'map' returns a *list*. This list can be coerced into an array or into a > hash (if it has an even number of elements). It's the same as literal > list assigment; you can both do: > > @array = (1,2,3,4); > %hash = (1,2,3,4); > > Also > > @array = (1,2,3); > > But not (gives an 'Odd number of elements in hash assignment' error): > > %hash = (1,2,3); > > But remember: map never returns a reference! See > > perldoc -f map > > for the details. > > -- > felix -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]