Home / Engineering / Problem Solving and Python Programming MCQs / Page 26

Problem Solving and Python Programming MCQs | Page - 26

Dear candidates you will find MCQ questions of Problem Solving and Python Programming here. Learn these questions and prepare yourself for coming examinations and interviews. You can check the right answer of any question by clicking on any option or by clicking view answer button.

M

Mr. Dubey • 51.17K Points
Coach

`Q. 251) return result`

(A) return a list containing every third item from l starting at index 0
(B) return an empty list
(C) return a list containing every third index from l starting at index 0
(D) return a list containing the items from l starting from index 0, omitting every third item

M

Mr. Dubey • 51.17K Points
Coach

`Q. 252) print(veggies)`

(A) [‘carrot’, ‘celery’, ‘broccoli’, ‘potato’, ‘asparagus’] correct 1.00
(B) [‘carrot’, ‘celery’, ‘potato’, ‘asparagus’]
(C) [‘carrot’, ‘broccoli’, ‘celery’, ‘potato’, ‘asparagus’]
(D) [‘celery’, ‘carrot’, ‘broccoli’, ‘potato’, ‘asparagus’]

M

Mr. Dubey • 51.17K Points
Coach

`Q. 253) >>>m = [[x, x + 1, x + 2] for x in range(0, 3)]`

(A) [[1, 2, 3], [4, 5, 6], [7, 8, 9]]
(B) [[0, 1, 2], [1, 2, 3], [2, 3, 4]]
(C) [1, 2, 3, 4, 5, 6, 7, 8, 9]
(D) [0, 1, 2, 1, 2, 3, 2, 3, 4]

M

Mr. Dubey • 51.17K Points
Coach

`Q. 254) m = [[x, y] for x in range(0, 4) fo r y in range(0, 4)]`

(A) 8
(B) 12
(C) 16
(D) 32

M

Mr. Dubey • 51.17K Points
Coach

`Q. 255) print(v)`

(A) 3
(B) 5
(C) 6
(D) 33

M

Mr. Dubey • 51.17K Points
Coach

`Q. 256) print(v)`

(A) 1
(B) 3
(C) 5
(D) 6

M

Mr. Dubey • 51.17K Points
Coach

`Q. 257) print(matrix[i][1], end = " ")`

(A) 1 2 3 4
(B) 4 5 6 7
(C) 1 3 8 12
(D) 2 5 9 13

M

Mr. Dubey • 51.17K Points
Coach

`Q. 258) print(m(row), end = " ")`

(A) 3 33
(B) 1 1
(C) 5 6
(D) 5 33

M

Mr. Dubey • 51.17K Points
Coach

`Q. 259) print(data[1][0][0])`

(A) 1
(B) 2
(C) 4
(D) 5

M

Mr. Dubey • 51.17K Points
Coach

`Q. 260) print(ttt(data[0]))`

(A) 1
(B) 2
(C) 4
(D) 5

Download our easy to use, user friendly Android App from Play Store. And learn MCQs with one click.