Python
Questions No: 1/50

The syntax used to rename a file :
फ़ाइल का नाम बदलने के लिए प्रयुक्त सिंटैक्स:

Questions No: 2/50

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

Questions No: 3/50

The ______ mode of Python gives instant result of typed statement
पायथन का ______ मोड टाइप किए गए कथन का तुरंत परिणाम देता है

Questions No: 4/50

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

Questions No: 5/50

Given a function that does not return any value, What value is thrown by default when executed in shell.
ऐसे फ़ंक्शन को देखते हुए जो किसी भी वैल्यू को रिटर्न नहीं करता है, शेल में एक्सक्यूटेड होने पर डिफ़ॉल्ट रूप से कौन सी वैल्यू को हटा दिया जाता है।

Questions No: 6/50

Given a string x="hello" What is the output of x.count('l')?
एक स्ट्रिंग x = "hello " को देखते हुए x.count ('1') का आउटपुट क्या है?

Questions No: 7/50

When we open file in append mode the file pointer is at the ______ of the file.
जब हम अपेंड मोड में फाइल खोलते हैं तो फाइल पॉइंटर फाइल के _____ पर होता है।

Questions No: 8/50

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

Questions No: 9/50

____is a string literal denoted by triple quotes for providing the specifications of certain program elements.
____एक स्ट्रिंग अक्षर है जिसे कुछ प्रोग्राम एलिमेन्टो के स्पेशिफिकेशन को प्रोवाइड करने के लिए ट्रिपल कोट्स द्वारा दर्शाया जाता है।

Questions No: 10/50

Which of the following functions is used to open a file in Python?
पायथन में फ़ाइल खोलने के लिए निम्नलिखित में से किस फ़ंक्शन का उपयोग किया जाता है?

Questions No: 11/50

How can assertions be disabled in Python?
पायथन में अभिकथनों को कैसे अक्षम किया जा सकता है?

Questions No: 12/50

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

Questions No: 13/50

What is full form of CSV?
सीएसवी का फुल फॉर्म क्या है?

Questions No: 14/50

Which of the following is not valid Python identifiers?
निम्नलिखित में से कौन वैध पायथन आइडेंटिफायर नहीं है?

Questions No: 15/50

What is the pickling?
पिकलिंग क्या है?

Questions No: 16/50

Which of the following is used to define a block of code in Python language ?
पायथन लैंग्वेज में कोड के ब्लॉक को परिभाषित करने के लिए निम्न में से किसका प्रयोग किया जाता है?

Questions No: 17/50

What is the output of the following code?

print(True and False)

Questions No: 18/50

What is the default mode for files in Python?
पायथन में फ़ाइलों के लिए डिफ़ॉल्ट मोड क्या है?

Questions No: 19/50

____ are the arguments passed to a function in correct positional order.
सही स्थिति क्रम में किसी फंक्शन को दिए गए आर्गुमेन्ट हैं।

Questions No: 20/50

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

Questions No: 21/50

What will the value of a if a=~100
यदि a=~100 है तो a का मान क्या है?

Questions No: 22/50

Each line of a text file is terminated by a special character, called the ___
टेक्स्ट फाइल की प्रत्येक पंक्ति को एक विशेष कैरेक्टर द्वारा समाप्त किया जाता है, जिसे ____ कहा जाता है।

Questions No: 23/50

Which of the following is not a valid identifier?
निम्न में से कौन सा वैध पहचानकर्ता नहीं है?

Questions No: 24/50

What is the output of the following code? print(not False)
निम्नलिखित कोड का परिणाम क्या है? print(not False)

Questions No: 25/50

What is the output of the following code?

a=set('abc')
b=set('cdef')
print(a&b)

Questions No: 26/50

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

Questions No: 27/50

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

Questions No: 28/50

What is can be the length of python identifier
पाइथन पहचानकर्ता की लंबाई क्या हो सकती है

Questions No: 29/50

______ are additional readable information to clarify the statement in python.
______ पायथन में कथन को स्पष्ट करने के लिए अतिरिक्त पठनीय जानकारी है।

Questions No: 30/50

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

Questions No: 31/50

Python code can run on a variety of platforms, it means Python is a _____ language.
पायथन कोड विभिन्न प्लेटफार्मों पर चल सकता है, इसका मतलब है कि पायथन एक _____ भाषा है।

Questions No: 32/50

What does readlines() method return ?
रीडलाइन () मेथड क्या रिटर्न करता है?

Questions No: 33/50

What will be the output of the following code ?

f=open("demo.txt","w+")
f.write("Welcome to python")
f.seek(5)
a=f.read(5)
print(a)

Questions No: 34/50

Which one is not the attribute of a file ?
इनमें से कौन एक फाइल की विशेषता नहीं है ?

Questions No: 35/50

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

Questions No: 36/50

What will be the output of : infile.read(2)
निम्नलिखित कोड का आउटपुट क्या होगा? infile.read(2)

Questions No: 37/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: 38/50

What will be the output of following?

Y=[2,5J,6]
Y.sort()

Questions No: 39/50

What keyword is used in Python to raise exceptions?
एक्सेप्शन उत्पन्न करने के लिए पायथन में किस कीवर्ड का उपयोग किया जाता है?

Questions No: 40/50

Which of the following is not a valid mode to open a file?
निम्नलिखित में से कौन सा फ़ाइल खोलने के लिए वैध मोड नहीं है?

Questions No: 41/50

What will be the output of the following Python code?

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

Questions No: 42/50

What will be the output of the following Python code?

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

Questions No: 43/50

What is unpickling?
अनपिकलिंग क्या है

Questions No: 44/50

What will be the output of the following Python code?

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

Questions No: 45/50

How many keywords present in the python programming language?
पायथन प्रोग्रामिंग भाषा में कितने कीवर्ड मौजूद हैं?

Questions No: 46/50

Which of these in not a core data type in python?
इनमें से कौन एक कोर डेटा प्रकार नहीं है?

Questions No: 47/50

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

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

Questions No: 48/50

What is the output of the following code ?

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

Questions No: 49/50

What is the output of the following?

x=123
for i in x:
    print(i)

Questions No: 50/50

What will be the output of the following Python code?

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