O Level - Sequence Data Types In Python
Questions No: 1/50

Suppose listExample is [3, 4, 5, 20, 5, 25, 1, 3], what is list1 after listExample.extend([34, 5])?
मान लीजिए लिस्ट है [3, 4, 5, 20, 5, 25, 1, 3] ,listExample.extend([34, 5]) के बाद की लिस्ट1 क्या है।

Questions No: 2/50

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

print('abcefd'.replace('cd', '12'))

Questions No: 3/50

Suppose a list with name arr, contains 5 elements. You can get the 2nd element from the list using :
मान लीजिए arr नाम वाली एक सूची में 5 तत्व हैं। आप सूची से दूसरा तत्व प्राप्त कर सकते हैं:

Questions No: 4/50

What is “Hello”.replace(“l”, “e”)?
"हैलो" .replace ("l", "e") क्या है?

Questions No: 5/50

What will be the output of the following Python code?

a={1:"A",2:"B",3:"C"}
b={4:"D",5:"E"}
a.update(b) 
print(a)

Questions No: 6/50

Set makes use of __________ Dictionary makes use of ____________
सेट __________ का यूज़ करता है शब्दकोश ____________ का यूज़ करता है

Questions No: 7/50

What is the correct command to shuffle the following list?

fruit=['apple', 'banana', 'papaya', 'cherry']

Questions No: 8/50

A sequence of immutable objects is called
अपरिवर्तनीय वस्तुओं का क्रम कहलाता है

Questions No: 9/50

Which operation extracts part of a sequence?
कौन सी क्रिया अनुक्रम के एक भाग को निकालती है?

Questions No: 10/50

Suppose listExample is [3, 4, 5, 20, 5, 25, 1, 3], what is list1 after listExample.pop()?
मान लीजिए सूची है। [3, 4, 5, 20, 5, 25, 1, 3], listExample.pop() के बाद लिस्ट1 क्या है।

Questions No: 11/50

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

Questions No: 12/50

What type of data is : arr=[(1,1),(2,2),(3,3)]?
किस प्रकार का डेटा है: arr=[(1,1),(2,2),(3,3)]?

Questions No: 13/50

Which statement is correct
कौन सा कथन सही है

Questions No: 14/50

What will be the output of the following Python code?

str1="helloworld"
print(str1[::-1])

Questions No: 15/50

Suppose list1 is [3, 4, 5, 20, 5, 25, 1, 3], what is list1 after list1.reverse()?
मान लीजिए कि list1 [3, 4, 5, 20, 5, 25, 1, 3] है, list1.reverse () के बाद list1 क्या है?

Questions No: 16/50

What will be the output of the following Python code?

>>> a={5,6,7}
>>> sum(a,5)

Questions No: 17/50

What is the output of following code

a=[1,2,3]
a[::-1]
print(a)

Questions No: 18/50

What will be the output?

dict1={'a':[3,6,8]}
print(len(dict1))

Questions No: 19/50

What will be the output of the following Python code?

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

Questions No: 20/50

What will be the output of the following Python code?

a=[10,23,56,[78]]
b=list(a)
a[3][0]=95
a[1]=34
print(b)

Questions No: 21/50

Dictionary has:
डिक्सनरी में है:

Questions No: 22/50

What will be the output of the following Python code?

print('ab'.isalpha())

Questions No: 23/50

Which method is used to add an element to the end of a list?
किसी लिस्ट के एन्ड में कोई एलिमेंट्स जोड़ने के लिए किस मेथड का यूज़ किया जा

Questions No: 24/50

What will be the output of the following Python code?

print("xyyzxyzxzxyy".endswith("xyy"))

Questions No: 25/50

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

>>> a={1:"A",2:"B",3:"C"}
>>> del a

Questions No: 26/50

What will be printed?

a = [1, 2, 3]
print(a * 2)

Questions No: 27/50

What will be the output of the following Python code?

string = "my name is x"
for i in string.split():
    print (i, end=", ")

Questions No: 28/50

What is the output of following code

a = [1,2,3]
del a[1]
print(a)

Questions No: 29/50

Which of the following are valid string manipulation functions in python?
निम्नलिखित में से कौन से पायथन में वैध स्ट्रिंग मैनिपुलेशन फ़ंक्शन हैं?

Questions No: 30/50

What will be the output of the following Python code?

d = {0: 'a', 1: 'b', 2: 'c'}
for x in d.keys():
    print(d[x])

Questions No: 31/50

Suppose list1 is [3, 4, 5, 20, 5, 25, 1, 3], what is the value of list1.count(5)?
मान लीजिए list1 [3, 4, 5, 20, 5, 25, 1, 3], है, list1.count(5) की क्या वैल्यू है।

Questions No: 32/50

To shuffle the list(say list1) what function do we use?
लिस्ट में शफल (फेरबदल) करने के लिए (say list1) हम किस फ़ंक्शन का यूज़ करते हैं?

Questions No: 33/50

Suppose list1 is [3, 4, 5, 20, 5, 25, 1, 3], what is list1.count(5)?
मान लीजिए कि लिस्ट1 है [3, 4, 5, 20, 5, 25, 1, 3], list1.count (5) क्या है?

Questions No: 34/50

What will be the output of the following Python code?

a={1:"A",2:"B",3:"C"}
a.clear() 
print(a)

Questions No: 35/50

What is the output of >>>’2’ +’3’
>>>'2' +'3' का आउटपुट क्या है

Questions No: 36/50

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

print(''.isdigit())

Questions No: 37/50

Which of the following function returns True if the string is non empty and has all uppercase alphabets.
यदि स्ट्रिंग नॉन-इम्पटी है और सभी अपरकेस अक्षर हैं, तो निम्न में से कौन सा फंक्शन सही है।

Questions No: 38/50

What will be the output of the following Python code?

print("xyyzxyzxzxyy".count('xyy', 2, 11))

Questions No: 39/50

What is the data type of (1)?
(1) का डेटा प्रकार क्या है?

Questions No: 40/50

To return the length of string s what command do we execute?
स्ट्रिंग की लेंथ रिटर्न करने के लिए हम किस कमांड को एक्सक्यूट करते हैं?

Questions No: 41/50

In which of the following data type, duplicate items are not allowed ?
निम्नलिखित में से किस डेटा प्रकार में डुप्लीकेट आइटम की अनुमति नहीं है?

Questions No: 42/50

What will be the output of the following Python code?

a=[(2,4),(1,2),(3,9)]
a.sort()
print(a)

Questions No: 43/50

What is the output when we execute

list("hello") ? 

Questions No: 44/50

What does the function re-search do?
फंक्शन re-search क्या करता है?

Questions No: 45/50

What will be the output of the following Python code?

values = [[3, 4, 5, 1], [33, 6, 1, 2]]
v = values[0][0]
for row in range(0, len(values)):
    for column in range(0, len(values[row])):
        if v < values[row][column]:
            v = values[row][column]
print(v)

Questions No: 46/50

which function is used to remove last item from a list?
किसी लिस्टसे अंतिम आइटम को हटाने के लिए किस फ़ंक्शन का उपयोग किया जाता है?

Questions No: 47/50

What is the output of following code

d = {1:"A", 2:"B", 1:"C"}
print(d)

Questions No: 48/50

Which type stores key-value pairs?
किस प्रकार का डेटा कुंजी-मान युग्मों को संग्रहीत करता है?

Questions No: 49/50

What will be the output of the following Python code?

myList = [1, 2, 3, 4, 5, 6]
for i in range(1, 6):
    myList[i - 1] = myList[i]     
for i in range(0, 6): 
    print(myList[i], end = " ")

Questions No: 50/50

What will be the output of the following Python code?

def f(values):
    values[0] = 44
   
v = [1, 2, 3]
f(v)
print(v)