Completed
Class 11 IP – Python & Lists Live Challenge
Questions From This Challenge
Q1mcq1 mark
Which statement correctly describes the difference between interactive mode and script mode in Python?
Interactive mode executes commands immediately, while script mode executes a saved program ✓
Interactive mode can execute only complete programs, while script mode executes one statement at a time
Both modes work only with programs saved in files
Script mode cannot contain comments
Q2output1 mark
What will be the output of the following Python code?
x = 8 y = 3 print(x + y * 2)
Correct output:
14Q3mcq1 mark
Which of the following is a valid Python identifier?
2marks
student-name
student_marks ✓
class
Q4output1 mark
What will be the output of the following Python code?
x = 10 x += 5 x *= 2 print(x)
Correct output:
30Q5output1 mark
What will be the output of the following Python code?
x = 15 y = 4 print(x // y) print(x % y)
Correct output:
3
3Q6mcq1 mark
Which statement about mutable and immutable data types is correct?
Mutable objects cannot be changed after creation
Immutable objects can be modified directly after creation
Lists are mutable, while numbers are immutable ✓
Lists and numbers are both immutable
Q7output1 mark
What will be the output of the following Python code?
x = 5
if x > 3:
x = x + 4
else:
x = x - 4
print(x)
Correct output:
9Q8output1 mark
What will be the output of the following Python code?
n = 18
if n > 20:
print("A")
elif n > 15:
print("B")
else:
print("C")
Correct output:
BQ9output1 mark
What will be the output of the following Python code?
x = 1
while x < 10:
x = x * 2
print(x)
Correct output:
16Q10output1 mark
What will be the output of the following Python code?
total = 0
for x in [2, 4, 6]:
total = total + x
print(total)
Correct output:
12Q11output1 mark
What will be the output of the following Python code?
numbers = [10, 20, 30] numbers.append(40) numbers.insert(1, 15) print(numbers)
Correct output:
[10, 15, 20, 30, 40]Q12output1 mark
What will be the output of the following Python code?
numbers = [5, 10, 5, 20, 5] print(numbers.count(5)) print(numbers.index(20))
Correct output:
3
3Q13output1 mark
What will be the output of the following Python code?
numbers = [10, 20, 30, 40] numbers.remove(20) x = numbers.pop() print(numbers) print(x)
Correct output:
[10, 30]
40Q14output1 mark
What will be the output of the following Python code?
numbers = [4, 1, 3, 2] numbers.sort() numbers.reverse() print(numbers)
Correct output:
[4, 3, 2, 1]Q15output1 mark
What will be the output of the following Python code?
numbers = [6, 2, 9, 4] print(len(numbers)) print(min(numbers) + max(numbers)) print(sum(numbers))
Correct output:
4
11
21