Monday 15 June 2015

Loops

L/O 1 - To understand what a loop is
L/O 2 - To understand how to use a simple for loop
L/O 3 - To develop computational thinking skills

Outcomes
Red - You will have created a hexagon using a for loop
Amber - You will have edited the colour, and position of the hexagon
Green - You will use the skills learnt to draw a simple house

Starter



Main


RED TASK

A) Type up your hexagon program
B) Save it as hexagon.py
C) Test it and make sure it works properly


AMBER TASK

A) Add this code to your hexagon.py program before for x in range(1,5):
Screen().bgcolor("yellow") 
terry.color("blue") 
terry.pensize(5)
B) Run your program what does this new code do?
C) Can you tweak the code?


GREEN TASK

A) Use this code to move to a new place on the screen and then draw a second hexagon
terry.penup() # pick up the pen
terry.goto(10,10) # go to a x and y position
terry.pendown() # put the pen down

B) Post your code on your computer science blog


EXTENSION TASK

A) Using what you have learnt draw a simple house like this one. You will need to use terry.begin_fill() And terry.end_fill()
B) Post your code on your computer science blog

Plenary


Code showcase!
Print your code to P676-1mon and stick it in your book

No comments:

Post a Comment

Elite of the Week

Create your free online surveys with SurveyMonkey , the world's leading questionnaire tool.

Year 10/11 Deadlines