2016-03-25 16:47:20 -07:00
|
|
|
# snowflake fall blocks challenges
|
|
|
|
|
|
|
|
Coding challenges for snowflake fall.
|
|
|
|
|
|
|
|
## Before we get started
|
|
|
|
|
2016-04-13 08:27:45 -07:00
|
|
|
Complete the [snowflake fall](/lessons/snowflake-fall/activity) activity and your code will look like this:
|
2016-03-25 16:47:20 -07:00
|
|
|
|
2016-03-30 15:11:05 -07:00
|
|
|
```blocks
|
|
|
|
basic.forever(() => {
|
|
|
|
basic.showLeds(`
|
|
|
|
. . . . .
|
|
|
|
. . # . .
|
|
|
|
. # # # .
|
|
|
|
. . # . .
|
|
|
|
. . . . .
|
|
|
|
`)
|
|
|
|
basic.showLeds(`
|
|
|
|
. . # . .
|
|
|
|
. # . # .
|
|
|
|
# . . . #
|
|
|
|
. # . # .
|
|
|
|
. . # . .
|
|
|
|
`)
|
|
|
|
})
|
|
|
|
```
|
2016-03-25 16:47:20 -07:00
|
|
|
|
2017-09-07 13:42:08 -07:00
|
|
|
## Challenge 1
|
2016-03-25 16:47:20 -07:00
|
|
|
|
2016-05-26 15:24:10 -07:00
|
|
|
|
2016-03-25 16:47:20 -07:00
|
|
|
|
|
|
|
To finalize our snowflake fall, let's add a different snowflake pattern.
|
|
|
|
|
2016-03-30 15:11:05 -07:00
|
|
|
```blocks
|
|
|
|
|
|
|
|
basic.forever(() => {
|
|
|
|
basic.showLeds(`
|
|
|
|
. . . . .
|
|
|
|
. . # . .
|
|
|
|
. # # # .
|
|
|
|
. . # . .
|
|
|
|
. . . . .
|
|
|
|
`)
|
|
|
|
basic.showLeds(`
|
|
|
|
. . # . .
|
|
|
|
. # . # .
|
|
|
|
# . . . #
|
|
|
|
. # . # .
|
|
|
|
. . # . .
|
|
|
|
`)
|
|
|
|
basic.showLeds(`
|
|
|
|
. # . # .
|
|
|
|
# # # # #
|
|
|
|
. # . # .
|
|
|
|
# # # # #
|
|
|
|
. # . # .
|
|
|
|
`)
|
|
|
|
})
|
|
|
|
|
|
|
|
```
|
|
|
|
|
2016-03-25 16:47:20 -07:00
|
|
|
|
|
|
|
* Run your program and see if it works.
|
|
|
|
|
2018-10-22 10:00:57 -07:00
|
|
|
## Challenge 2
|
2016-03-25 16:47:20 -07:00
|
|
|
|
|
|
|
Add a fourth frame to the current animation... or make it your own!
|
|
|
|
|