pxt-calliope/docs/reference/js/lessons/looper.md

81 lines
2.5 KiB
Markdown
Raw Normal View History

2016-03-26 00:47:20 +01:00
# looper lesson
Learn to control blinking LEDs. #LED #screen #for #docs
### @video td/videos/looper-0
## Topic
For Loop
## Quick links
* [tutorial](/microbit/lessons/looper/tutorial)
* [quiz](/microbit/lessons/looper/quiz)
* [quiz answers](/microbit/lessons/looper/quiz-answers)
* [challenges](/microbit/lessons/looper/challenges)
## Class
Year 7
## Prior learning/place of lesson in scheme of work
Learn how to control a blinking LED. We will be learning how to create a blinking app using the for loop as well as simple commands, such as plot and pause.
## Documentation
* **for**: [read more...](/microbit/reference/loops/for)
* **show number**: [read more...](/microbit/reference/basic/show-number)
* **pause**: [read more...](/microbit/reference/basic/pause)
* **arithmetic operators**: [read more...](/microbit/reference/types/number)
## Objectives
* learn how to repeat code a fixed number of times
* learn how to show a number on the LED screen, one digit at a time (scrolling from left to right)
* learn how to pause program execution for the specified number of milliseconds
* learn how to arithmetic operators operate on numbers and return a number
## Progression Pathways / Computational Thinking Framework
#### Algorithms
* Uses logical reasoning to predict outputs, showing an awareness of inputs. (AL)
* Understands that iteration is the repetition of a process such as a loop. (AL)
* Represents solutions using a structured notation. (AL) (AB)
#### Programming & Development
* Creates programs that implement algorithms to achieve given goals. (AL)
* Uses a variable and relational operators within a loop to govern termination. (AL) (GE)
* Uses a range of operators and expressions e.g. Boolean, and applies them in the context of program control. (AL)
#### Data & Data Representation
* Understands the difference between data and information. (AB)
* Defines data types: real numbers and Boolean. (AB)
#### Information Technology
* Collects, organises and presents data and information in digital content. (AB)
* Makes appropriate improvements to solutions based on feedback received, and can comment on the success of the solution. (EV)
Computational Thinking Concept: AB = Abstraction; DE = Decomposition; AL = Algorithmic Thinking; EV = Evaluation; GE = Generalisation
## Activity
* time: 10 min.
* [tutorial](/microbit/lessons/looper/tutorial)
* [quiz](/microbit/lessons/looper/quiz)
## Extended Activity
* time: 20 min.
* [challenges](/microbit/lessons/looper/challenges)
## Homework
* Extended Activity: [challenges](/microbit/lessons/looper/challenges)