codehs: Unit 2 Lessons 13 to 19

codehs: Unit 2 Lessons 13 to 19

9th - 12th Grade

15 Qs

quiz-placeholder

Similar activities

Модуль Turtle в Python

Модуль Turtle в Python

9th Grade

10 Qs

Unit 2 Review

Unit 2 Review

9th - 12th Grade

17 Qs

Python - Turtle - Plenary

Python - Turtle - Plenary

6th Grade - University

16 Qs

Tracy Intro to Programming Test

Tracy Intro to Programming Test

10th Grade

20 Qs

Quiz Pemrograman Python Turtle

Quiz Pemrograman Python Turtle

11th Grade

20 Qs

Exploring Computer Science

Exploring Computer Science

9th - 10th Grade

14 Qs

Turtle Lesson 1

Turtle Lesson 1

11th Grade

10 Qs

Intro to Python Turtle Graphics 2.1-2.4 [50 points]

Intro to Python Turtle Graphics 2.1-2.4 [50 points]

9th Grade

20 Qs

codehs: Unit 2 Lessons 13 to 19

codehs: Unit 2 Lessons 13 to 19

Assessment

Quiz

Computers

9th - 12th Grade

Hard

Created by

Christine Marra

Used 128+ times

FREE Resource

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

Why are parameters useful?

They allow us to tailor functions to be used in multiple situations

They allow us to change the order of commands in a function

They give us the ability to use variables in loops

They allow the user to give input

2.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

How many parameters can we use in each function?

1

2

4

As many as we need

3.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

What is the best way to write a program that uses parameters to draw a square with sides that are 50 pixels long?

def make_square(length):

for i in range(4):

forward(length)

left(90)


make_square(50)

def make_square(length):

for i in range(4):

forward(50)

left(90)


make_square(50)

def make_square(50):

for i in range(4):

forward(50)

left(90)


make_square(50)

def make_square(length):

for i in range(4):

forward(length)

left(90)


make_square(length)

4.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

What is the default starting value of i in a for loop?

0

1

2

10

5.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

What will the values of i be at each iteration of the loop below?

  1. for i in range(3):

1, 2, 3

0, 1, 2, 3

0, 1, 2

2, 3

6.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

What will happen when the value of i reaches 5 in the loop below?

for i in range(5):

left(i)

right(90)

Tracy will turn 5 degrees to the right

Tracy will turn 5 degrees to the left

Tracy will turn 90 degrees to the right

Tracy will turn 90 degrees to the left

7.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

Why do we use if statements?

To tell Tracy to stop our code if there’s an error

To have Tracy make decisions based on conditional statements

To tell Tracy to do something if we run our code

To have Tracy complete one function at a time

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?