Generation

generate functionSat, 12 Nov 2022

New function to Array prototype that returns its length

Array.prototype.length = function(){ return this.length; }; ['a', 'b', 'c'].length(); // 3

Javascript
Generate More

Questions about programming?Chat with your personal AI assistant