Array length: Difference between revisions

reformatted as a draft task and adding proper headings, moving the see also section up and not making that a heading.
No edit summary
(reformatted as a draft task and adding proper headings, moving the see also section up and not making that a heading.)
Line 1:
{{draft task}}
Determine the amount of elements in an array.
<br>As an example use an array holding the strings 'apple' and 'orange'.
 
== ;See also ==:
== JavaScript ==
* [[String length]]
 
== {{header|JavaScript }}==
 
<lang javascript>console.log(['apple', 'orange'].length);</lang>
 
== {{header|PHP }}==
 
<lang php>print count(['apple', 'orange']); // Returns 2</lang>
 
== {{header|SQL }}==
 
<lang sql>SELECT COUNT() FROM (VALUES ('apple'),('orange'));</lang>
 
== See also ==
 
* [[String length]]
Anonymous user