+ 2

What is your favorite way to write arrays?

4th Aug 2016, 10:29 AM
Sudeep Kumar Devulapally
Sudeep Kumar Devulapally - avatar
3 Answers
+ 1
var array = ["1", "2"];
4th Aug 2016, 2:24 PM
Kamil
Kamil - avatar
0
As a side note: JavaScript does not support associative arrays. You should use objects when you want the element names to be strings (text) and use arrays when you want the element names to be numbers. Var
5th Aug 2016, 2:48 AM
Tee
Tee - avatar
0
classic way in javascript and push method in php
15th Nov 2016, 9:52 AM
Ludovich MĂŒuller
Ludovich MĂŒuller - avatar