Skip to content

Commit 490d264

Browse files
authored
Remove duplicated last step from Python version of 'Smiley Buttons' (#5738)
* remove duplicated last step * hide step headings
1 parent c959630 commit 490d264

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

docs/projects/python/smiley-buttons.md

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@
22

33
### @explicitHints true
44

5-
## Introduction @unplugged
5+
## Code a micro:bit emoji! @unplugged
66

77
Code the buttons on the @boardname@ to show that it's happy or sad.
88
(Want to learn how the buttons works? [Watch this video](https://youtu.be/t_Qujjd_38o)).
99

1010
![Pressing the A and B buttons](/static/mb/projects/smiley-buttons/sim.gif)
1111

12-
## Step 1
12+
## {Step 1}
1313

1414
Put in an ``||input:on button pressed||`` event to run code when button **A** is pressed.
1515

@@ -19,7 +19,7 @@ def on_button_pressed_a():
1919
input.on_button_pressed(Button.A, on_button_pressed_a)
2020
```
2121

22-
## Step 2
22+
## {Step 2}
2323

2424
Use ``||basic:show icon||`` to display a **Happy** face on the screen.
2525

@@ -31,7 +31,7 @@ def on_button_pressed_a():
3131
input.on_button_pressed(Button.A, on_button_pressed_a)
3232
```
3333

34-
## Step 3
34+
## {Step 3}
3535

3636
Use another ``||input:on button pressed||`` with a ``||basic:show icon||`` inside to display a **Sad** face when button **B** is pressed.
3737

@@ -41,7 +41,7 @@ def on_button_pressed_a2():
4141
input.on_button_pressed(Button.B, on_button_pressed_a2)
4242
```
4343

44-
## Step 4
44+
## {Step 4}
4545

4646
Add a secret mode that happens when **A** and **B** are pressed together. For this case, use ``||basic:show icon||`` multiple times to create an animation.
4747

@@ -52,10 +52,6 @@ def on_button_pressed_a3():
5252
input.on_button_pressed(Button.AB, on_button_pressed_a3)
5353
```
5454

55-
## Step 5
55+
## {Step 5}
5656

5757
Click ``|Download|`` to transfer your code to your @boardname@ (if you have one). Try buttons **A**, **B** and then **A** and **B** together.
58-
59-
## Step 6
60-
61-
If you have a @boardname@ connected, click ``|Download|`` and transfer your code to the @boardname@!

0 commit comments

Comments
 (0)