pxt-calliope/docs/reference/js/lessons/blink/quiz-answers.md

47 lines
1.2 KiB
Markdown
Raw Normal View History

2016-03-26 00:47:20 +01:00
# blink quiz answers
Learn how to create a blinking LED script.
This is the answer key for the [blink quiz](/microbit/lessons/blink/quiz).
## 1. Describe what `led->plot` does?
Answers will vary. In general, plot refers to the code that turns on a specific LED. We specify the LED using x, y coordinates.
## 2. Draw which LED is ON after running this code
```
led.plot(2, 2)
```
![](/static/mb/lessons/blink-0.png)
By default, the position of an LED on *Blink Tutorial* is set to the centre of the screen. This code turns on the centre LED
## 3. Draw which LED is ON after running this code
```
led.plot(0, 0)
```
![](/static/mb/lessons/blink-1.png)
This code turns on specific LED. Plot turns on the specified LED on the LED screen. We specify the LED using x, y coordinates.
* ``x`` - the x coordinate or horizontal position (0)
* ``y`` - the y coordinate or vertical position (0)
## 4. Draw which LED is ON after running this code
```
led.plot(4, 4)
```
![](/static/mb/lessons/blink-2.png)
This code turns on specific LED. Plot turns on the specified LED on the LED screen. We specify the LED using ``x``, ``y`` coordinates.
* ``x`` - the x coordinate or horizontal position (4)
* ``y`` - the y coordinate or vertical position (4)