Copyright © tutorialspoint.com
Javascript array length property returns an unsigned, 32-bit integer that specifies the number of elements in an array.
array.length |
Here is the detail of parameters:
NA
Returns the length of the array.
<html> <head> <title>JavaScript Array length Property</title> </head> <body> <script type="text/javascript"> var arr = new Array( 10, 20, 30 ); document.write("arr.length is : " + arr.length); </script> </body> </html> |
This will produce following result:
arr.length is : 3 |
To understand it in better way you can Try it yourself.
Copyright © tutorialspoint.com