+ 6

Function variable inside variable

I tried this but it doesnt work it just uses var instead of the string that the variable contains. function test(var){ otherFunction(var,true); }

23rd Apr 2018, 8:04 PM
Arne Van Kerckvoorde
Arne Van Kerckvoorde - avatar
2 Respostas
+ 3
var isnt a valid variable name and this should produce an error,var is a keyword so i dont understand your question
23rd Apr 2018, 8:19 PM
᠌᠌Code X
᠌᠌Code X - avatar
+ 2
This was just an example the variable name is cost
23rd Apr 2018, 9:26 PM
Arne Van Kerckvoorde
Arne Van Kerckvoorde - avatar