Can I add 10th element without the other first 9 in an arrow?? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Can I add 10th element without the other first 9 in an arrow??

11th May 2020, 12:48 PM
Sigauq
Sigauq - avatar
11 Answers
+ 5
Yes of course. You can add the 10th element without the other 9 arrays. var courses = new Array(); courses[9] = "JS";
11th May 2020, 1:06 PM
James Clark I. Vinarao
James Clark I. Vinarao - avatar
+ 2
what course?
11th May 2020, 12:48 PM
James Clark I. Vinarao
James Clark I. Vinarao - avatar
+ 1
JavaScript
11th May 2020, 12:49 PM
Sigauq
Sigauq - avatar
+ 1
What you mean ; to select or to add
11th May 2020, 12:50 PM
James Clark I. Vinarao
James Clark I. Vinarao - avatar
+ 1
Add
11th May 2020, 12:50 PM
Sigauq
Sigauq - avatar
+ 1
Give example of code.
11th May 2020, 12:50 PM
James Clark I. Vinarao
James Clark I. Vinarao - avatar
+ 1
"JavaScript arrays are dynamic, so you can declare an array and not pass any arguments with the Array() constructor. You can then add the elements dynamically." This is the context
11th May 2020, 12:53 PM
Sigauq
Sigauq - avatar
+ 1
just wait.
11th May 2020, 1:03 PM
James Clark I. Vinarao
James Clark I. Vinarao - avatar
+ 1
Yes.
11th May 2020, 1:07 PM
yochanan sheinberger
yochanan sheinberger - avatar
+ 1
James Clark I. Vinarao that was what I was saying
11th May 2020, 1:10 PM
Bensen
0
Sigauq Yeah of course it is possible But the other elemets may contain either zero or any garbage values
11th May 2020, 12:51 PM
Bensen