3.3.2021

What would the JavaScript error say?

var numbers = [1, 2, 3, 4, 5];
numbers.length = 3;

Answer: In JS it is possible to set the length of a array. => numbers = [1, 2, 3]

Jan

Softwareentwickler

Zur Übersicht

Standort Hannover

newcubator GmbH
Bödekerstraße 22
30161 Hannover

Standort Dortmund

newcubator GmbH
Westenhellweg 85-89
44137 Dortmund