Python
Questions No: 1/50

What is the output of the following code?

def s(n1):
    print(n1)
    n1=n1+2
n2=4
s(n2)
print(n2)

Questions No: 2/50

Which symbol is used to write single line comment ?
सिंगल लाइन कमेंट लिखने के लिए किस चिन्ह का प्रयोग किया जाता है ?

Questions No: 3/50

In which format Binary file contains information?
बाइनरी फ़ाइल में सूचना किस प्रारूप में होती है?

Questions No: 4/50

Which is a valid Constant in python
जो कि पायथन में एक मान्य स्थिरांक है

Questions No: 5/50

Which of the following is not a keyword in python?
निम्नलिखित में से कौन सा पायथन में एक कीवर्ड नहीं है?

Questions No: 6/50

How is a code block indicated in Python?
पायथन में कोड ब्लॉक को कैसे दर्शाया जाता है?

Questions No: 7/50

Which one of the following is the correct extension of the Python file ?
निम्नलिखित में से कौन सा पायथन फाइल का सही एक्सटेंशन है-

Questions No: 8/50

What will be the output of the following expression ?

x =4
print(x<<2)

Questions No: 9/50

What will be the output of the following pseudocode, where ^ represent XOR operation ?

Integer a, b, c
set b = 4, a = 3
c =a ^ b
Print c

Questions No: 10/50

How can you close a file in Python after processing?
प्रसंस्करण के बाद आप पायथन में किसी फ़ाइल को कैसे बंद कर सकते हैं?

Questions No: 11/50

A Function used for writing data in the binary format :
बाइनरी फॉर्मेट में डेटा लिखने के लिए उपयोग किया जाने वाला एक फंक्शन:

Questions No: 12/50

What will be the output of the following Python code?

x = 'abcd'
for i in range(len(x)):
    print(i)

Questions No: 13/50

What will be the result of the expression print(5 and 10) ?
print(5 and 10) का परिणाम क्या होगा?

Questions No: 14/50

Give the output of: print(2^5)
इसका आउटपुट क्या होगा : print(2^5)

Questions No: 15/50

Is Python case sensitive when dealing with identifiers?
क्या पहचानकर्ताओं के साथ व्यवहार करते समय पायथन केस सेंसिटिव है?

Questions No: 16/50

What does tell() return?
tell() क्या return करता है?

Questions No: 17/50

What will be the output of the following Python code?

x = ['ab', 'cd']  
for i in x:      
    x.append(i.upper())  
print(x)

Questions No: 18/50

Which of the following is an invalid mode?
निम्न में से कौन सा अमान्य मोड है?

Questions No: 19/50

What is the output?

f = open("test.txt", "w")
f.write("Python")
print(f.tell())
f.close()

Questions No: 20/50

Which of these are keyword?
इनमें से कौन से कीवर्ड हैं ?

Questions No: 21/50

Which can contain multiple lines of text.
जिसमें टेक्स्ट की कई पंक्तियाँ हो सकती हैं।

Questions No: 22/50

which of the following will read entire content of file (file object 'f')?
निम्नलिखित में से कौन फ़ाइल (file object 'f') की संपूर्ण सामग्री को पढ़ेगा ?

Questions No: 23/50

Which method is used to read the entire content of a file as a string in Python?
पायथन में फ़ाइल के पूरे डाटा को स्ट्रिंग के रूप में पढ़ने के लिए किस फंक्शन का उपयोग किया जाता है?

Questions No: 24/50

Which of the following is not a relational opeartor in Python?
निम्नलिखित में से कौन पायथन में एक रिलेशनल ऑपरेटर नहीं है?

Questions No: 25/50

In order to store values in terms of key and value we use what core data type.
की और वैल्यू के संदर्भ में वैल्यूज को स्टोर करने के लिए हम किस कोर डेटा प्रकार का यूज़ करते हैं।

Questions No: 26/50

Which of the following mode will refer to binary data?
निम्न में से कौन सा मोड बाइनरी डेटा को संदर्भित करेगा?

Questions No: 27/50

The tiny individual unit in python program is known as
पायथन प्रोग्राम में छोटी व्यक्तिगत इकाई को कहा जाता है

Questions No: 28/50

Which of the following options can be used to read the first line of a text file data.txt?
टेक्स्ट फाइल data.txt की पहली लाइन को पढ़ने के लिए निम्न में से कौन सा विकल्प इस्तेमाल किया जा सकता है?

Questions No: 29/50

Which of the following error is returned when we try to open a file in write mode which does not exist?
जब हम किसी ऐसी फ़ाइल को राइट मोड में खोलने की प्रयास करते हैं जो मौजूद नहीं है तो निम्न में से कौन सी एरर दिखाई देती है

Questions No: 30/50

What will be the output of the following Python code?

x = "abcdef"
i = "i"
while i in x:
    print(i, end=" ")

Questions No: 31/50

What is the Full form of EOL?
EOL का फुल फॉर्म क्या है?

Questions No: 32/50

Which of the following mode argument is used in file to truncate ?
निम्नलिखित में से किन मोड आर्गुमेंट का उपयोग ट्रंकेट करने के लिए उपयोग किया जाता है?

Questions No: 33/50

What is the output of the following code ?

def fun(a, b=6):
    a=a+b
    print(a)
fun(5, 4)

Questions No: 34/50

Which mode creates a new file if the file does not exist?
यदि फ़ाइल मौजूद नहीं है तो कौन सा मोड एक नई फाइल बनाता है?

Questions No: 35/50

Default argument values are evaluated:
Default argument values कब evaluate होती हैं?

Questions No: 36/50

Which keyword skips current iteration?
कौन सा कीवर्ड वर्तमान पुनरावृति को छोड़ देता है?

Questions No: 37/50

If a function doesn't have a return statement, which of the following does the function return ?
यदि किसी फंक्शन का रिटर्न स्टेटमेंट नहीं है, तो निम्न में से कौन सा फंक्शन रिटर्न होता है?

Questions No: 38/50

What does the 'r' mode signify when opening a file using open() in Python?
पायथन में ओपन() का उपयोग करके फ़ाइल खोलते समय 'r' मोड क्या दर्शाता है?

Questions No: 39/50

What is the return type of function id?
फ़ंक्शन आईडी का रिटर्न प्रकार क्या है?

Questions No: 40/50

What is the output of the following code?

print(True and False)

Questions No: 41/50

What does read() do?
read() क्या करता है?

Questions No: 42/50

What happens if a file opened in w mode already exists?
यदि file पहले से मौजूद है और उसे w mode में खोला जाए तो क्या होता है?

Questions No: 43/50

which is a correct way to open a file in python
पायथन में फ़ाइल खोलने के लिए किस फ़ंक्शन का उपयोग किया जाता है?

Questions No: 44/50

What is the output of below program ?

def say(message, times =1):
    print(message * times)
say("Hello")
say("Word",5)

Questions No: 45/50

Which of the following declarations is incorrect?
निम्नलिखित में से कौन सी डेक्लरेशंस गलत है?

Questions No: 46/50

What will the following code output?

a=‘INFOMAX’ 
a=10
print(type(a))

Questions No: 47/50

The data type whose representation is known are called
वह डेटा प्रकार जिसका प्रतिनिधित्व ज्ञात हो, कहलाते हैं

Questions No: 48/50

What will be the output of the following Python code?

def foo():
    return total + 1
total = 0
print(foo())

Questions No: 49/50

Python is ________ Programming Language
पायथन एक _____ प्रोग्रामिंग है

Questions No: 50/50

what is 'f' in the following statement?

f=open("Data.txt","r")