Loading…
None
String updated in the repository |
|
None
String updated in the repository |
|
Loading…
None
String updated in the repository |
|
None
String updated in the repository |
|
To do so, you start a line of code with the [code]var[/code] keyword followed by your desired variable name. Like [code]func[/code] stands for [i]function[/i], [code]var[/code] stands for [i]variable[/i].
Variables are case-sensitive, which means [code]health[/code] and [code]Health[/code] are technically different variables. Be careful to use the same capitalization wherever you refer to the same variable, or you could be reading or writing to a different variable.
The following line defines a [code]health[/code] variable pointing to no value. You can think of it as creating a product label you have yet to stick onto something.
Para hacer esto, comienza una línea de código con la palabra clave [code]var[/code] seguida del nombre de la variable que desees. Al igual que [code]func[/code] significa [i]función[/i], [code]var[/code] significa [i]variable[/i].
Las variables distinguen entre mayúsculas y minúsculas, lo que significa que [code]salud[/code] y [code]Salud[/code] son técnicamente variables diferentes. Ten cuidado de utilizar las mismas mayúsculas siempre que te refieras a la misma variable, o podrías estar leyendo o escribiendo en una variable diferente.
La siguiente línea define una variable [code]health[/code] que no apunta a ningún valor. Puedes pensar en ello como crear una etiqueta de un producto que aún tienes que pegar en algo.