page-banner
Python M3-R5.1 MCQs SET-6
Q16.
पायथन में निम्नलिखित में से कौन से वैध एस्केप सीक्वेंस हैं?

Which of the following are valid escape sequences in Python?
A. \n
B. \t
C. \\
D. All of the above
View Answer
Q17.
कथन 2 के लिए उत्तर चुनें।

Choose the answer for statement 2.

import ___________ # statement 1
rec = [ ]
while True:
    rn = int(input("Enter"))
    nm = input("Enter")
    temp = [rn, nm]
    rec.append(temp)
    ch = input("Enter choice (Y/N)")
    if ch.upper == "N":
        break
f = open("stud.dat", "____________") #statement 2
__________ .dump(rec, f) #statement 3
_______.close( ) # statement 4
A. w
B. wb
C. w+
D. write
View Answer
Q18.
मान लें कि 4 बाइनरी में 100 है और 11 1011 है। निम्नलिखित बिटवाइज़ ऑपरेटरों का आउटपुट क्या है?

Let us assume 4 is 100 in binary and 11 is 1011. What is the output of the following bitwise operators ?

a = 4
b = 11
print(a | b)
print(a >> 2)
A. 15 , 1
B. 14 , 1
C. 17 , 2
D. 16 , 2
View Answer
Q19.
जब हम list("hello") निष्पादित करते हैं तो आउटपुट क्या होता है?

What is the output when we execute list("hello")?
A. ['h', 'e', 'l', 'l', 'o']
B. [' hello']
C. ['llo']
D. ['olleh']
View Answer
Q20.
निम्नलिखित में से कौन-सा अपरिवर्तनीय डेटा प्रकार है?

Which one of the following is immutable data type?
A. list
B. set
C. tuple
D. dict
View Answer

Create Account