
![[IGCS] For-loop with tutle](https://cf.quizizz.com/img/presentation/default-img/presentation_title_img-1_idea.jpg?w=200&h=200)
[IGCS] For-loop with tutle
Presentation
•
Social Studies, Computers
•
9th Grade
•
Practice Problem
•
Hard
Andy tsui
Used 6+ times
FREE Resource
11 Slides • 2 Questions
1
[IGCS] For-loop with tutle

2
Introducing Turtle graphics
In REPL.it, start a new "Python with Turtle" project
Name it with "for-loop-with-turtle"
On the first two line, do:
3
Enter the following in your new REPL
import turtle
t = turtle.Turtle()
4
Run, and on the command console, try:
t.forward(50)
t.left(50)
Note what are they doing? and can you guess how to go backward and rotate right?
5
Drawing regular shapes
Try to draw a square
6
Fill in the Blanks
Type answer...
7
Now try to draw the square with For-loop
8
Multiple Choice
Now we try to draw equilateral triangle, we need to repeat 3 times the following:
t.forward(50)
t.right([X])
What is X?
60
120
30
150
9
120 is the exterior angle
Can you recall the formula for it?
10
Exterior angle of n-side polygon
ext_angle = 360 / n
11
Practice time, using for loops to:
Draw a Pentagon of each side 20 unit long
Draw a Hexagon of 20 unit long
Draw an Octagon of 20 unit long
Draw a Decagon of 20 unit long
12
Finding the pattern
In a regular polygon:
for i in range (n):
⠀t.forward(20)
⠀t.right(?)
13
Summary
For loop is for counting and the counter can be used as a variable
It is usually not advisable to change the counter value inside the loop
[IGCS] For-loop with tutle

Show answer
Auto Play
Slide 1 / 13
SLIDE
Similar Resources on Wayground
7 questions
The Importance of Water
Presentation
•
9th Grade
11 questions
Lesson 6.2 | Part 2 - War & Empire
Presentation
•
8th - 9th Grade
10 questions
System of Linear Inequalities
Presentation
•
9th Grade
8 questions
Power, Authority and Rule of Law
Presentation
•
9th Grade
10 questions
Voluntary Migration
Presentation
•
9th Grade
10 questions
LÀM QUEN CHỮ CÁI O, Ô, Ơ
Presentation
•
KG
10 questions
Adding/Subtracting Integers Intervention
Presentation
•
9th Grade
8 questions
History of the Blues
Presentation
•
9th Grade
Popular Resources on Wayground
24 questions
PBIS-HGMS Day 10
Quiz
•
6th - 8th Grade
10 questions
HCS SCI 03 Summer School Review 3
Quiz
•
3rd Grade
11 questions
Home Scope
Quiz
•
7th - 8th Grade
15 questions
HCS SCI 05 Summer School Assessment 3 Review
Quiz
•
5th Grade
35 questions
Lufkin Road Middle School Student Handbook & Policies Assessment
Quiz
•
7th Grade
18 questions
Geo 11.3 Area of Circles and Sectors
Quiz
•
9th - 11th Grade