1var length = 5;
2var array = [];
3var i = 0;
45for (i = 0; i != length; i++){
6 array.push(i)
7//array.push is used to push a value inside array8}
910console.log(array);
1112//console.log is used to check array value inside your console
you will get a confirmation link on this - you will have to click that for successful submission of your answer. we require this to keep the website free of spam, bots and unhelpful content
please ensure to add code which is syntactically corrent and executes properly
you will get a confirmation link on this - you will have to click that for successful submission of your question. we require this to keep the website free of spam, bots and unhelpful content