Font size
WorksheetsTerm 1 Year 8
Total questions: 100
Worksheet time: 1hrs 18mins
name = 'Dave'
print (name)
name = 'Dave'
greeting = "Good morning" + name
print (greeting)
people = ["John", "Rob", "Bob"]
print (people[1])
what would this result be?
people = ["John", "Rob", "Bob"]
print (people[-1])
what would this result be?
people = ["John", "Rob", "Bob"]
print (people[4])
what would this result be?
print(Hello world!)
print("Hello world!")
Print("Hello world!")
print(3+4)
print("3+4")
print(3*4)
print(3*4+5)
print("3*4+5")
print(9/3)
print(9/3*2+4-5)
print("Hello" + "world!")
print("Hello" + "world" + "today")
print("Hello" + str(2) + "world!")
print("Hello world!\nHello world!")
Hello world!
print("Hello world!" * 2)
print(2 + 3.0)
Score = Score + 1
Which of the following is the correct way to print hello world in Python?
Print("hello world")
PRINT(hello world)
print(hello world)
print("hello world")
Which of the following is the correct way to create a square?
turtle.forward(100)
turtle.right(90)
turtle.forward(100)
turtle.left(90)
turtle.forward(100)
turtle.right(90)
turtle.forward(100)
turtle.left(90)
turtle.forward(100)
turtle.left(90)
turtle.forward(100)
turtle.left(90)
turtle.forward(100)
turtle.left(90)
turtle.forward(100)
turtle.left(90)
turtle.forward(100)
turtle.left(180)
turtle.forward(100)
turtle.left(180)
turtle.forward(100)
turtle.left(180)
turtle.forward(100)
turtle.left(180)
turtle.forward(100)
turtle.left(90)
turtle.forward(200)
turtle.left(90)
turtle.forward(100)
turtle.left(90)
turtle.forward(200)
turtle.left(90)
What is the operator for multiplication?
*
x
**
What is the correct operator for greater than or equal to?
<
>=
<=
>
Find the line of code with an error:
print("good morning")
colour = input("what colour would you like?")
Print("good morning")
color = input("what colour would you like?")
To change the turtle line colour I would use:
turtle.pencolour("Red")
turtle.pencolour(Red)
turtle.pencolor("Red")
turtle.pencolor(Red)
for counter in range(3):
turtle.forward(100)
turtle.right(180)
This code will draw a...
square
rectangle
circle
triangle
if number == 10:
print("That's high")
elif number >= 5:
print("That's quite high")
else:
print("That's pretty low")
If I enter 9 into this program, what will I get out?
An error
That's quite high
That's pretty low
That's high
if number == 10:
print("That's high")
elif number >= 5:
print("That's quite high")
else:
print("That's pretty low")
If I enter 0 into this program, what will I get out?
An error
That's quite high
That's pretty low
That's high
Which of the following lines of code is correct?
name = input("what is your name?"
name = Input("what is your name?")
name = input("what is your name?")
name = INPUT("what is your name?")
name = input("what is your name")
