Home
O Level
M1 R5: Information Technology Tools and Network Basics
Introduction to Computers
Office Automation Tools
Internet and Web Technologies
Networking Fundamentals
M2 R5: Web Designing and Publishing
HTML
CSS
Javascript
Web Hosting And Publishing
M3 R5: Programming and Problem Solving through Python
Introduction to Programming
Python Programming
Data Structures in Python
File Processing in Python
M4 R5: Internet of Things (IoT) and Its Applications
Introduction to IoT
IoT Architecture
IoT Applications
IoT Security and Challenges | Soft Skills
Other Courses
Under Graduate Courses
BA
BCA
B.COM
Post Graduate Courses
MCA
MBA
M.COM
MA
M.SC.(MATHS)
MSW
Institutional Courses
DCA
ADCA
DFA
DOAP
TALLY PRIME
JAVA
PYTHON
CCA
C Languages
Job Oriented Courses
Digital Marketing
Full Stack Development
Data Science
Cybersecurity and Ethical Hacking
Blockchain Development
Cloud Computing
Artificial Intelligence (AI) and Machine Learning
Government Courses
CCC
O LEVEL
A LEVEL
Mock Test
M1 R5: Information Technology Tools and Network Basics
M2 R5: Web Designing and Publishing
M3 R5: Programming and Problem Solving through Python
M4 R5: Internet of Things (IoT) and Its Applications
Old Papers
2024
New!
Assignments
HTML
New!
CSS
New!
Javascript
New!
Python
New!
Log in
Sign Up
O Level Papers!
M3 R5: Programming and Problem Solving through Python
Set
25
See Explanation !
1
What will be the output of the following Python code? a=[(2,4),(1,2),(3,9)] a.sort() print(a)
निम्नलिखित पायथन कोड का आउटपुट क्या होगा? a =[(2,4),(1,2),(3,9)] a.sort() print(a)
[(1, 2), (2, 4), (3, 9)]
[(2,4),(1,2),(3,9)]
Error because tuples are immutable
Error, tuple has no sort attribute
Next Question
25
See Explanation !
2
Which one of the following is incorrect?
निम्नलिखित में से कौन सा गलत है?
The variables used inside function are called local variables.
The local variables of a particular function can be used inside other functions, but these cannot be used in global space.
The variables used outside function are called global variables.
In order to change the value of global variable inside function, keyword global is used.
Previous Question
Next Question
25
See Explanation !
3
What will be the output of the following Python code? a={1:"A",2:"B",3:"C"} b=a.copy() b[2]="D" print(a)
निम्नलिखित पायथन कोड का आउटपुट क्या होगा? a={1:"A",2:"B",3:"C"} b=a.copy() b[2]="D" print(a)
Error, copy() method doesn’t exist for dictionaries
{1: ‘A’, 2: ‘B’, 3: ‘C’}
{1: ‘A’, 2: ‘D’, 3: ‘C’}
“None” is printed
Previous Question
Next Question
25
See Explanation !
4
What will be the output of the following Python code? x='abcd' for i in x: print(i.upper())
निम्नलिखित पायथन कोड का आउटपुट क्या होगा? x='abcd' for i in x: print(i.upper())
a BCD
abcd
error
A B CD
Previous Question
Next Question
25
See Explanation !
5
Which of the following data types is not supported in python?
पायथन में निम्नलिखित में से कौन सा डेटा प्रकार समर्थित नहीं है?
Number
String
List
Slice
Previous Question
Next Question
25
See Explanation !
6
Give the output of: print(2^5)
इसका आउटपुट क्या होगा : print(2^5)
32
7
10
3
Previous Question
Next Question
25
See Explanation !
7
in python which function is used to read CSV file
पायथन में CSV फ़ाइल को पढ़ने के लिए किस फ़ंक्शन का उपयोग किया जाता है?
csv.reader(file)
csv.read(file)
csv.readcsv(file)
csv.readcsvdata(file)
Previous Question
Next Question
25
See Explanation !
8
What will be the output of the following Python code snippet? print(not(3>4)) print(not(1&1))
निम्नलिखित पायथन कोड स्निपेट का आउटपुट क्या होगा? print(not(3>4)) print(not(1)
True True
True False
False True
False False
Previous Question
Next Question
25
See Explanation !
9
What will be the result of the following expression in Python “2 ** 3 + 5 ** 2”?
पायथन में निम्नलिखित अभिव्यक्ति "2 ** 3 + 5 ** 2" का परिणाम क्या होगा?
65536
33
169
None of the above
Previous Question
Next Question
25
See Explanation !
10
Which method is used to add an element to the end of a list?
सूची के अंत में किसी तत्व को जोड़ने के लिए किस विधि का उपयोग किया जाता है?
insert()
append()
extend()
add()
Previous Question
Next Question
25
See Explanation !
11
Which of these is not true about recursion?
इनमें से कौन सा रिकर्शन के बारे में सच नहीं है?
Making the code look clean
A complex task can be broken into sub-problems
Recursive calls take up less memory
Sequence generation is easier than a nested iteration
Previous Question
Next Question
25
See Explanation !
12
Extension of python module is
पायथन मॉड्यूल का एक्सटेंशन क्या है
.mod
.module
.py
.python
Previous Question
Next Question
25
See Explanation !
13
How many for loop structure we can use in our program?
हम अपने प्रोग्राम में कितने फॉर लूप स्ट्रक्चर का यूज़ कर सकते हैं?
Only One
1-10
Any number of Times
Any number of times but one inside another only.
Previous Question
Next Question
25
See Explanation !
14
Suppose d = {"john”:40, “peter":45}. To obtain the number of entries in dictionary which command do we use?
मान लीजिए कि d = {" जॉन ":40, "पीटर ":45}। शब्दकोश में प्रविष्टियों की संख्या प्राप्त करने के लिए हम किस आदेश का उपयोग करते हैं?
d.size()
len(d)
size(d)
d.len ()
Previous Question
Next Question
25
See Explanation !
15
f.read(5) will read________from a file (file object 'f')
f.read(5) एक फ़ाइल से________ पढ़ेगा (file object 'f')
5 characters
5 words
5 lines
None of the above
Previous Question
Next Question
25
See Explanation !
16
Which function is used to get the Data Type of any value?
किसी भी मान का डेटा प्रकार प्राप्त करने के लिए किस फ़ंक्शन का उपयोग किया जाता है?
type()
data_type()
datatype()
dataType()
Previous Question
Next Question
25
See Explanation !
17
Which one of the following is the correct extension of the Python file-
निम्नलिखित में से कौन सा पायथन फ़ाइल का सही विस्तार है -
.py
.python
.p
None of these
Previous Question
Next Question
25
See Explanation !
18
Which one of the following is the correct way of calling a function?
निम्नलिखित में से कौन-सा एक फंक्शन को कॉल करने का सही तरीका है?
function_name()
call function_name()
ret function_name()
function function_name()
Previous Question
Next Question
25
See Explanation !
19
What will the following code output? a=55 | b=55 | print( a is not b)
निम्नलिखित कोड आउटपुट क्या होगा? a=55 | b=55 | print( a b नहीं है)
True
False
55
TypeError
Previous Question
Next Question
25
See Explanation !
20
The code block within every function starts with a ____ ?
प्रत्येक फंक्शन के भीतर एक कोड ब्लॉक ... से शुरू होता है?
;
: :
:
%
Previous Question
Next Question
25
See Explanation !
21
What is 'pass' in python?
पायथन में 'pass' क्या है?
No Operation
No Action
Null Statement
Placeholder
Previous Question
Next Question
25
See Explanation !
22
Which of these about a frozenset is not true?
फ्रोजेनसेट के बारे में इनमें से कौन सा सच नहीं है?
Mutable data type
Allows duplicate values
Data type with unordered values
Immutable data type
Previous Question
Next Question
25
See Explanation !
23
What is a correct syntax to create a NumPy array?
NumPy array बनाने के लिए सही सिंटैक्स क्या है?
np.array([4,5,6])
np.create_array([4,5,6])
np.createArray([4,5,6])
np.numpyArray([4,5,6])
Previous Question
Next Question
25
See Explanation !
24
The output of this expression, >>>6*1**3 is ____ .
इस अभिव्यक्ति का आउटपुट, >>>6*1**3 ____ है।
6
18
10
None of these
Previous Question
Next Question
25
See Explanation !
25
Which of the following expressions is an example of type conversion?
निम्नलिखित में से कौन सा व्यंजक प्रकार रूपांतरण का एक उदाहरण है?
4.0 + float(3)
5.3 + 6.3
5.0 + 3
3 + 7
Previous Question