Logo
학교 방탈출
quiz thumbnail
Freestyle
Middle 6
Tech

Ekskul Phyton 2

avatar

LUKAS SETYO WI

9

20 questions

Allow incorrect answer

Hide answer

public quiz

# 1Multiple Choice

name = "bungmanoon"

print(name)

price = 100

print(price)

"bungmanoon" 100
bungmanoon 100
bungmanoon
100
# 2Multiple Choice

Output?

Question image
Pyhton
Programming
Pyhton Programming
Pyhton Programming Pyhton Programming
# 3Multiple Choice

What is a correct syntax to output "Hello World" in Python?

print("Hello World")
echo "Hello World"
echo("Hello World");
p("Hello World")
# 4Multiple Choice

Which one is NOT a legal variable name?

_myvar
my_var
Myvar
my-var
# 5Multiple Choice

What is the correct file extension for Python files?

.py
.pt
.pyth
.pyt
# 6Multiple Choice

How do you create a variable with the floating number 2.8?

x = 2.8
x = float(2.8)
Both answers are correct
# 7Multiple Choice

What is the correct syntax to output the type of a variable or object in Python?

print(type(x))
print(typeof(x))
print(typeOf(x))
print(typeof x)
# 8Multiple Choice

Which operator is used to multiply numbers?

%
#
*
x
# 9Multiple Choice

Which operator can be used to compare two values?

=
==
<>
><
# 10Multiple Choice

How do you start writing an if statement in Python?

if (x > y)
if x > y then:
if x > y:
# 11Multiple Choice

How do you start writing a while loop in Python?

while x > y:
while (x > y)
while x > y {
x > y while {
# 12Multiple Choice

Which statement is used to stop a loop?

stop
exit
break
return
# 13Multiple Choice

print('52+2')

52
2
52+2
54
# 14Multiple Choice

print('4+5=',4+5)

4+5=9
4+5=4+5
9=9
4=4 5=5
# 15Multiple Choice

Choose which one is true!

num1 = 30 num2 = 9 division = num1 / num2 print("The result of " + str(num1) + " / " + str(num2) + " = " + str(Division))
num1 = 30 num2 = 9 division = num1 / num2 print("The result of " + str(num1) + " / " + str(num2) + " = " + int(division))
num1 = 30 num2 = 9 division = num1 / num2 print("The result of " + str(num1) + " / " + str(num2) + " = " + str(division))
num1 = 30 num2 = 9 division = num1 / num2 print("The result of " + int(num1) + " / " + int(num2) + " = " + str(division))
# 16Multiple Choice

How to write an input and output command in Phyton text editor that will result like below? The variable input is name.

Please enter your name:

Hi, Aan

name = input(Please enter your name:) print("Hi, "+name)
name = (int(input("Please enter your name:")) print("Hi, "+name)
name = input("Please enter your name:") print("Hi, "+str(name))
name = input(Please enter your name:) print("Hi, "+name)
# 17Multiple Choice

Function used to convert data into numbers:

string()
print()
int()
input()
# 18Multiple Choice

a=5<4

b=10<20

print("a or b = ",a or b)

error
a and b = true
a and b = false
5<4 and 10<20
# 19Multiple Choice

print(3**2)

3
6
9
12
# 20Multiple Choice

Do we need to put the indentation/space after a loop program?

YES
NO
MAYBE
Share to Google Classroom

This quiz was created using a premium map. Access is restricted due to plan expiration.