Re: for/in loop Array gotcha



On 29/09/2005 16:49, Ian Osgood wrote:

[snip]

for (var i in u)

[snip]

(i+1) does not obtain the expected results because i is a string!

Of course, because property names are /always/ strings.

[snip]

Mike

--
Michael Winter
Prefix subject with [News] before replying by e-mail.
.



Relevant Pages