lesson updates

This commit is contained in:
Michael Elliot Braun
2016-03-30 11:15:31 -07:00
70 changed files with 221 additions and 196 deletions

View File

@ -12,27 +12,28 @@ Answers may vary. Generally, on button pressed run code when an input button is
Write the line of code that creates a condition when the BBC micro:bit button A is pressed.
```blocks
input.onButtonPressed(Button.A, () => {
input.onButtonPressed(Button.A, () => {
})
```
## 3. Consider the following directions
## 3. Write the line of code that creates a **local variable** and a **random number**.
Write the line of code that creates a **local variable** and a **random number**.
```blocks
let randomNumber = Math.random(10)
```
## 4. Consider the following code
## 4.
If the rectangle below represents the BBC micro:bit, shade the areas that will be displayed. Explain why that particular area is shaded.
```blocks
randomNumber = Math.random(10)
```
If the rectangle below represents the BBC micro:bit, shade the areas that will be displayed. Explain why that particular area is shaded.
![](/static/mb/lessons/guess-the-number-0.png)