mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-03-02 02:01:39 -05:00
fix(curriculum): Updated code example for RPG game explanation on variables (#53519)
This commit is contained in:
@@ -10,10 +10,10 @@ dashedName: step-7
|
||||
Variables can be <dfn>assigned</dfn> a value. When you do this while you declare it, this is called <dfn>initialization</dfn>. For example:
|
||||
|
||||
```js
|
||||
let camperbot = "Bot";
|
||||
let age = 32;
|
||||
```
|
||||
|
||||
This would initialize the `camperbot` variable with a value of `Bot`, a string.
|
||||
This would initialize the `age` variable with a value of `32`, a number.
|
||||
|
||||
Initialize your `xp` variable to have a value of `0`, a number.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user