What\'s the most efficient way to create this simple array dynamically.
var arr = [ \"1\", \"2\", \"3\", \"4\", \"5\", \"6\", \"7\", \"8\", \"9\", \"10\"];
<
for (var j = 0; j <= data.legth -1; j++) {
lang += data.lang +", " ;
}
var langs = lang.split(',')
console.log("Languages =>", lang, typeof(lang), typeof(langs), langs)
console.log(lang[0]) // here access arrary by index value
you can see the type of string and object