page-banner
Chapter-5 (Part-1) Sequence Data Types
Q46.
निम्नलिखित कोड का परिणाम क्या है?

What is the output of the following code?
M = ['b' * x for x in range(4)]
print(M)
A. ['', 'b', 'bb', 'bbb']
B. ['b', 'bb', 'bbb', 'bbbb']
C. ['b', 'bb', 'bbb']
D. None of these
View Answer
Q47.
निम्नलिखित पाइथन कोड का परिणाम क्या है?

What is the output of the following Python code?
a = set('abc')
b = set('cdef')
print(a & b)
A. {'c'}
B. {'a', 'b', 'c', 'd', 'e', 'f'}
C. {c}
D. None of these
View Answer
Q48.
निम्नलिखित पाइथन कोड का परिणाम क्या है?

What is the output of the following Python code?
list1 = [1, 3]
list2 = list1
list1[0] = 4
print(list2)
A. [1, 4]
B. [1, 3, 4]
C. [4, 3]
D. [1, 3]
View Answer
Q49.
निम्नलिखित स्निपेट का परिणाम क्या है?

What is the output of the following snippet?
num = (4, 7, 19, 2, 89, 45, 72, 22)
y = sorted(num)
z = [x for x in y if x % 2 != 0]
print(z)
A. [7, 19, 45, 89]
B. [2, 4, 22, 72]
C. [4, 7, 19, 2, 89, 45, 72, 22]
D. [2, 4, 7, 19, 22, 45, 72, 89]
View Answer
Q50.
निम्नलिखित स्निपेट का परिणाम क्या है?

What is the output of the following code snippet?
print([i.lower() for i in 'HELLO'])
A. hello
B. ['h', 'e', 'l', 'l', 'o']
C. hel
D. HELLO
View Answer

Create Account