GATE DA Python Data Structures & Collections | Set 1

Questions 1-5 of 100

0% completed (0/100 answered)
Your score 0/100 0 answered
Correct 0 Incorrect 0 Unanswered 100 Accuracy 0%

Question 1

MCQ · Single Correct 1 mark

What will be the output of the following Python code snippet?

L = [10, 20, 30, 40, 50, 60, 70]
print(L[1:6:2])

Answers for question 1

Question 2

MCQ · Single Correct 1 mark

Consider the code below. What is the value of result after execution?

nums = [1, 2, 3]
result = nums * 2
result[0] = 99
print(nums)

Answers for question 2

Question 3

MCQ · Single Correct 1 mark

What is the output of the following code involving list methods?

a = [1, 2, 3]
b = a.append(4)
print(a, b)

Answers for question 3

Question 4

MCQ · Single Correct 1 mark
Previous Year Question GATE DA 2025 PYQ

What is the output of the following code using extend and append?

x = [1, 2]
y = [3, 4]
x.append(y)
z = [1, 2]
z.extend(y)
print(len(x), len(z))

Answers for question 4

Question 5

NAT · Numerical Answer 1 mark

What will be the output printed by the following Python code?

matrix = [[0]*3]*3
matrix[0][0] = 5
print(sum(matrix[1]))

Answers for question 5
Scroll to Top