Ver Mensaje Individual
  #2 (permalink)  
Antiguo 27/04/2012, 08:10
Avatar de Dafonz
Dafonz
 
Fecha de Ingreso: octubre-2009
Mensajes: 127
Antigüedad: 14 años, 6 meses
Puntos: 36
Respuesta: como funciona esta declaracion de variable?

Cita:
If you assign values to variables that have not yet been declared, the variables will automatically be declared as global variables.
These statements:
x=5;
carname="Volvo";
will declare the variables x and carname as global variables (if they don't already exist)
http://www.w3schools.com/js/js_variables.asp