-
Question of
What is the output of print(2 * 3)?
-
a) 6
-
b) 23
-
c) 5
-
d) Error
-
-
Question of
Which keyword defines a function in Python?
-
a) func
-
b) def
-
c) function
-
d) define
-
-
Question of
How do you create a list in Python?
-
a) (1, 2, 3)
-
b) {1, 2, 3}
-
c) [1, 2, 3]
-
d) <1, 2, 3>
-
-
Question of
What does len(“Hello”) return?
-
a) 5
-
b) “H”
-
c) “Hello”
-
d) 6
-
-
Question of
Which operator checks equality in Python?
-
a) =
-
b) ==
-
c) !=
-
d) ===
-
-
Question of
What is the result of “hi” * 2?
-
a) “hihi”
-
b) “hi2”
-
c) “hihihi”
-
d) Error
-
-
Question of
Which data type is mutable?
-
a) tuple
-
b) int
-
c) list
-
d) str
-
-
Question of
How do you start a for loop from 0 to 4?
-
a) for i in 5:
-
b) for i in range(5):
-
c) for i in (0, 4):
-
d) for i = 0 to 4:
-
-
Question of
Which method adds an item to a list?
-
a) .append()
-
b) .add()
-
c) .insert()
-
d) .push()
-
-
Question of
What does “hello”.upper() return?
-
a) “HELLO”
-
b) “Hello”
-
c) “hello”
-
d) “hELLO”
-
This post was created with our nice and easy submission form. Create your post!


GIPHY App Key not set. Please check settings