file_1739418390_Revision questions.
file_1739418390_Revision questions.
P =P + "Over" # Statement 5
A. Statement 3 B. Statement 4 C. Statement 5 D. Statement 4
and 5
6. What is the output of the following?
print('Final Chandra Dharishan'.split('a'))
A. ['Fin', 'l Ch', 'ndr', ' Dh', 'rish', 'n']
B. 'Fin', 'l Ch', 'ndr', ' Dh', 'rish', 'n'
C. Both A & B
D. None of the above
7. What will be the output for the following Python statement?
T=(10,20,[30,40,50],60,70)
T[2][1]=100
print(T)
A. Error.
B. (10,20,[30,100,50],60,70)
C. (10,20,[100,40,50],60,70)
D. None of these
8. Evaluate the following expressions:
print(5 // 10 * 9 % 3 ** 8 + 8 - 4)
A. 445 B. 4 C. 1232 D. 15626
9. Select the correct output of the code:
mystr = ‘Python programming is fun!’
mystr = mystr.partition(‘pro’)
mystr=’$’.join(mystr)
print(mystr)
A. Python $programming is fun!
B. Python $pro$gramming is fun!
C. Python$ pro$ gramming is fun!$
D. P$ython $p$ro$gramming is $fun!
10. Write the output of the code given below.
str1="Eight (8) Astakham!"
rstr1 = ''
index = len(str1)
Arsha Vidya Mandir
Lecture Notes -2024-25
while index>0:
if str1[index-1].isalpha():
rstr1+=str1[index-1]
index = index-1
print(rstr1)
A. Index Error
B. mahkatsAthgiE
C. Exceeding the index limit
D. MKhkatsAthgiE
11. Write the output of the code given below:
a,b,c,d = (1,2,3,4)
mytuple = (a,b,c,d)*2+(5**2,)
print(len(mytuple)+2)
A. 8 B. 16 C. 11 D. 50
12. Write the output of the following Python program code:
TXT = ["10","20","30","5"]
CNT = 3
TOTAL = 0
for C in [7,5,4,6]:
T = TXT[CNT]
TOTAL = float (T) + C
print (TOTAL, end='*')
CNT-=1
A. 12.0*35.0*24.0*16.0*
B. 12.0*10.0*9.0*11.0*
C. Type error
D. None of the options
13. Find the output of the following code:
M=[25,8,75,12,90,91]
for i in range(len(M)):
if M[i]%5 == 0:
M[i] //= 5
if M[i]%3 == 0:
M[i] //= 3
for i in M :
Arsha Vidya Mandir
Lecture Notes -2024-25
print(i, end='#')
A. 5#8#5#4#6#91#
B. 5#8#15#4#15#91#
C. Index out of range
D. 5#8#5#4#6#91
14. Select the correct output of the code:
L1, L2 = [10, 23, 36, 45, 78], [ ]
for i in range :
L2.insert(i, L1.pop( ) )
print( L1, L2, sep=’@’)
A. [78, 45, 36, 23, 10] @ [ ]
B. [10, 23, 36, 45, 78] @ [78, 45, 36, 23, 10]
C. [10, 23, 36, 45, 78] @ [10, 23, 36, 45, 78]
D. [ ] @ [78, 45, 36, 23, 10]
15. Predict the output of the code given below:
x=[1,2,3]
ctr=0
while ctr<len(x):
print(x[ctr]*'#',end=',')
for y in x:
print(y*'$',end=' ')
ctr+=1
A. #,$ $$ $$$ ##,$ $$ $$$ ###,$ $$ $$$
B. $,# ## $#$ ##,$ $$ $$$ ###,$ $$ $$$
C. Index error
D. Infinite loop
16. Find the output:
line="2044 Zodiac Cosmic Calendar 2023"
x=line[::-1]
print(x[0:4:1][::-1])
A. 2023 B. 2044 C. Calendar D. Index error
17. What possible outputs are expected to be displayed on screen at the time of execution
of
the program from the following code?
Arsha Vidya Mandir
Lecture Notes -2024-25
import random
print(random.randint(15,25) , end=' ')
print((100) + random.randint(15,25) , end = ' ' )
print((100) -random.randint(15,25) , end = ' ' )
print((100) *random.randint(15,25) )
A. 15 122 84 2500
B. 21 120 76 1500
C. 105 107 105 1800
D. 110 105 105 1900
18. Predict the output:
L=[1,4,9,16,35,27]
l=[num/3 for num in L if num%3==0]
print(l)
l=[1,2,5,6]
k=[e1*r for e1 in l if (e1-4)>1 for r in l[:4]]
print(k)
A. [3.0, 9.0]
[6, 12, 30, 36]
B. [3, 9]
[6, 12, 30, 36]
C. [3.0, 9.0]
[36, 30, 12, 6]
D. Error
19. What will be the output of the following Python code?
l=[1,2,3,4,5]
l[1:2]=[7,8]
print(l)
A. [1,2,3,4,5]
B. [1, 7, 8, 3, 4, 5]
C. [1, [7, 8], 3, 4, 5]
D. Syntax error
Arsha Vidya Mandir
Lecture Notes -2024-25
33. Write a program to calculate the second maximum and minimum element in a list.
34. Write a Python program to search and remove the given key from a dictionary.
35. Write a program to count the number of consonants present in a string using sets.
Computer organization.
36. Compare the following operators: ‘is’ and ‘= =’.
37. Define type conversion. Explain with a suitable example.
38. Define the id() function. Explain with a suitable example.
39. Define algorithm and flowchart.
40. What makes a compiler different from an interpreter?
41. Write a code to implement the concept of mutability and immutability.
42. Write a program to print the multiplication table.
43. Write a program to print the ASCII characters of characters from A to Z.
44. Define O.S and list out open source operating system.
Social impacts.
45. Describe the following cybercrimes: i) Cyberbullying. ii)Cyberstalking.
46. What do you mean by phishing and pharming?
47. What do you understand by identity theft and digital footprint?
48. Define Firewall.
49. The following is a 32-bit binary number usually represented as 4 decimal
values, each representing 8 bits, in the range 0 to 255 (known as
octets) and separated by decimal points. 140.179.220.200. What is it?
What is its importance?
50. Write two applications of cyber law?
51. Kabir wants to purchase a book online, and he has placed the order for that
book using an e-commerce website. Now, he is going to pay the amount
for that book online using his Mobile, then he needs which of the following
to complete the online transaction:-
A. A bank account,
B. Mobile phone which is attached to the above bank account,
C. The mobile banking app of the above bank is installed on that mobile,
Arsha Vidya Mandir
Lecture Notes -2024-25
******