Re: <FAQENTRY> ; Array and hash (associative array)
JRS: In article <lNmte.53057$G8 .43058@text.new s.blueyonder.co .uk>,
dated Sun, 19 Jun 2005 22:59:29, seen in news:comp.lang. javascript,
Michael Winter <m.winter@bluey onder.co.invali d> posted :[color=blue]
>On 19/06/2005 22:18, Dr John Stockton wrote:
>[color=green]
>> JRS: In article <ll565nwe.fsf@h otpop.com>, dated Sun, 19 Jun 2005
>> 18:09:37, seen in news:comp.lang. javascript, Lasse Reichstein Nielsen
>> <lrn@hotpop.com > posted :
>>[color=darkred]
>>> [...] the length property only guarantees to be at least one larger
>>> than the highest array index in use [...][/color]
>>
>> ^ integer ?[/color]
>
>Array indicies are a subset of object property names, and are only
>defined in terms of 32-bit unsigned integers, so it would seem redundant.[/color]
Commonly, that which is used in conjunction with an array name to
indicate a specific element of an array will be considered, rightly or
wrongly, to be an array index; so ISTM useful to include an adjective as
a reminder even if it is in truth superfluous.
BTW, I should have included non-negative; good languages can allow
negative indexes.
[color=blue]
>Could I ask a small favour of you, John? Can you check if IE4 supports
>String.prototy pe.charCodeAt? Microsoft's documentation says it doesn't,
>but my copy does. Though it is running on XP, it has a separate
>jscript.dll library and should be independent from the system libraries.
>It is with regard to other methods like Array.prototype .push.[/color]
Not sure what you mean there.
"qwertyuiop".ch arCodeAt(5)
has the value 121, matching "y" and
"qwer\u0646yuio p".charCodeAt(5 ) -> 121
"qwer\u0646yuio p".charCodeAt(4 ) -> 1606 d wok / dt
Otherwise, if you send test code I'll try it.
--
© John Stockton, Surrey, UK. ?@merlyn.demon. co.uk Turnpike v4.00 IE 4 ©
<URL:http://www.jibbering.c om/faq/> JL/RC: FAQ of news:comp.lang. javascript
<URL:http://www.merlyn.demo n.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demo n.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.
JRS: In article <lNmte.53057$G8 .43058@text.new s.blueyonder.co .uk>,
dated Sun, 19 Jun 2005 22:59:29, seen in news:comp.lang. javascript,
Michael Winter <m.winter@bluey onder.co.invali d> posted :[color=blue]
>On 19/06/2005 22:18, Dr John Stockton wrote:
>[color=green]
>> JRS: In article <ll565nwe.fsf@h otpop.com>, dated Sun, 19 Jun 2005
>> 18:09:37, seen in news:comp.lang. javascript, Lasse Reichstein Nielsen
>> <lrn@hotpop.com > posted :
>>[color=darkred]
>>> [...] the length property only guarantees to be at least one larger
>>> than the highest array index in use [...][/color]
>>
>> ^ integer ?[/color]
>
>Array indicies are a subset of object property names, and are only
>defined in terms of 32-bit unsigned integers, so it would seem redundant.[/color]
Commonly, that which is used in conjunction with an array name to
indicate a specific element of an array will be considered, rightly or
wrongly, to be an array index; so ISTM useful to include an adjective as
a reminder even if it is in truth superfluous.
BTW, I should have included non-negative; good languages can allow
negative indexes.
[color=blue]
>Could I ask a small favour of you, John? Can you check if IE4 supports
>String.prototy pe.charCodeAt? Microsoft's documentation says it doesn't,
>but my copy does. Though it is running on XP, it has a separate
>jscript.dll library and should be independent from the system libraries.
>It is with regard to other methods like Array.prototype .push.[/color]
Not sure what you mean there.
"qwertyuiop".ch arCodeAt(5)
has the value 121, matching "y" and
"qwer\u0646yuio p".charCodeAt(5 ) -> 121
"qwer\u0646yuio p".charCodeAt(4 ) -> 1606 d wok / dt
Otherwise, if you send test code I'll try it.
--
© John Stockton, Surrey, UK. ?@merlyn.demon. co.uk Turnpike v4.00 IE 4 ©
<URL:http://www.jibbering.c om/faq/> JL/RC: FAQ of news:comp.lang. javascript
<URL:http://www.merlyn.demo n.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demo n.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.
Comment