The Magic Behind Array Length Property
Developer deals with arrays every day. Being a collection, an important property to query is the number of items: Array.prototype.length.
In JavaScript the length does not always indicate the number of existing elements (for sparse arrays) and modifying this property may remove elements.

#javascript #array #js #programming

The Magic Behind Array Length Property
1.90 GEEK