
Banana Tales II quiz
Authored by Kelzang Lethro
Instructional Technology
8th Grade
Used 1+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Complete the code to define a class named Car.
define Car:
class Car: (Correct)
function Car():
Car = class()
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Fill in the blank to create a constructor that initializes the x and y properties.
def constructor(self):
def __init__(self): (Correct)
def method(self):
def Drill(self):
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Complete the code to create an object (instance) of the Drill class.
Drill = my_drill()
my_drill = Drill
my_drill = Drill() (Correct)
create my_drill = Drill()
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Add the missing code to call the drill_right method on the drill_1 object.
call drill_right()
Drill.drill_right()
drill_1.drill_right() (Correct)
drill_right(drill_1)
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Fill in the blank to get user input from the keyboard and store it in the answer variable.
answer = get("Type 'up' or 'down': ")
answer = "Type 'up' or 'down': "
answer = input("Type 'up' or 'down': ") (Correct)
input(answer, "Type 'up' or 'down': ")
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Complete the code to convert the user's string input into an integer.
age = str_to_int(age_str)
age = integer(age_str)
age = age_str.to_integer()
age = int(age_str) (Correct)
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Fill in the if condition to check if the age is greater than or equal to 18.
if age >= 18: (Correct)
if age > 18:
if age == 18:
if age is 18:
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?