Skip to content

Programming and Problem Solving through Python (M3-R5.1)- NIELIT O Level

  • by

You Have 2 hours To Complete The Test / Quiz


Programming and Problem Solving through Python (M3-R5.1)

Total available questions is More than 1000.

Each exam has 100 questions & Answers randomly.

You will get 2 hrs to complete the test.

Its Mandatory To Fill For Get Certificate After Complete Exam.

1) ______ are the modes of both writing and reading in binary format in file.

2) What is the current syntax of remove() a file ?

3) What is the full form of IDLE in Python

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

print('__foo__'.isidentifier())

5) Which of the following defines what an object can do?

6) What is the data type of (1)?

7) What will be the output of the following expression ?

x =4
print(x<<2)

 

9) Suppose list1 is [3, 4, 5, 20, 5, 25, 1, 3], what is list1 after list1.reverse()?

10) Which of the following statement is false about recursion:

11) What will be the output of the following Python code?

  A = [[1, 2, 3],        [4, 5, 6],        [7, 8, 9]]  [A[row][1] for row in (0, 1, 2)]

12) Which of the following is a Python tuple?

13) What will be the output of the following Python code?

print('a B'.isalpha())

14) Which of the following is not an advantage of using modules?

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

for i in [1, 2, 3, 4][::-1]:      print (i)

16) The diamond shape symbol is used to place a condition in the program.

17) The command is used to take input from the keyboard.

18) In which year was the Python 3.0 version developed?

19) _____ help programmers to create lists in a concise way.

20) What will be the output of the following Python code?

>>> a={3,4,5}  >>> b={5,6,7}  >>> a|b

21) What will be the output after following statements?

x = 2
if x < 5:
     print(x)
else:
    pass

22) To use a module in another module, you must import it using an, statement

24) A sequence of instruction, in a computer language, to get the desired result is known as

26) Python programming language was create by ______.

27) What will be the output of the following Python code?

  num = ['One', 'Two', 'Three']  for i, x in enumerate(num):      print('{}: {}'.format(i, x),end=" ")

28) What function do you use to read a string?

29) Diagram that represents steps or operations involved in any kind of process is called

30) Empty list indicated by which symbol.

32) To insert 5 to the third position in list1, we use which command?

33) What will be the output of the following Python statement?

>>>"abcd"[2:]

34)

35) What is identity array?

36) Which symbol is used to write single line comment ?

37) What is the value of the expression 10 + 3 ** 3 * 2?

38) Function range(0, 5, 2) will yield on iterable sequence like

39) Which of the following is the use of function in python ?
Loading question image..Pls wait.

40) What will be the output of the following Python code ?
Loading question image..Pls wait.

41) Which of the following is not a token ?

42) Error does not fall into any category

43) Which of the following environment variable for Python tells the Python interpreter where to locate the module files imported into a program?

44) What will be the output of the following Python code?

  i = 0  while i < 5:      print(i)      i += 1      if i == 3:          break  else:      print(0)

 

45) What will be the output of the following Python code ?

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

for i in a:

print (i, end=" ")

46) What will be the output of the following Python statement?

>>>"a"+"bc"

47) What will be the output of the following code snippet?

a = 2.19
b=3.999999
C= -3.30
printint((a), floor(b), ceil(c), fabs(c))

48) The function that yields current position in the file

49) Function range(10, 5, 2) will yield an iterable sequence like

50) Which function is used to converts and returns the binary equivalent string of a given integer.

51) Which of the following functions cannot be used on heterogeneous sets?

52) What will be the output of the following Python code?

>>> s={5,6}  >>> s*3

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

  x = 'abcd'  for i in range(len(x)):      i[x].upper()  print (x)

54) What will be the output of the following Python code?

>>> a={1,2,3}

>>> b=a    >>> b.remove(3)

>>> a

55) Python operator always yields the result of

56) What will be the output of the following Python code?

print("abc DEF".capitalize())

57) If a=(1,2,3,4), a[1:-1] is _________

58) The ______ statement lets the program go through the piece of code without performing any action.

59) Numpy was developed by___ .

60) Which module is to be imported for using randint() function?

61) A function used for writing data in the binary format:

62) Suppose listExample is [3, 4, 5, 20, 5, 25, 1, 3], what is list1 after listExample.extend([34, 5])?

63) What arithmetic operators cannot be used with strings?

64)

65) The operator returns the quotent after division.

66) ____ is a set of functions you want to include in your application.

67)

68) What does the following code print?

69) Array processing package.

70) What will be the output of the following Python code?

  i = 1  while True:      if i%0O7 == 0:          break      print(i)      i += 1

72) How can we create on empty list in Python?

73)
What is the output of the following?
n=5
while n>0:
n-=1
if n==2:
continue
print(n)

74) Python myfile.py is used to ____ file in command shell.

75) What will be the output of the following Python code?

names = ['Amir', 'Bear', 'Charlton', 'Daman']
print(names[-1][-1])

76) Suppose listExample is [3, 4, 5, 20, 5, 25, 1, 3], what is list1 after listExample.pop(1)?

77) What is identity array?

78)

79) Which of the following is an invalid statement in python.

80) A detailed flowchart is know as

81) Who developed Python ?

82) Which type of Programming does Python support?

83) Select the reserved keyword in python.

84) All instructions are executed one after other.

85) What will be the output of the following Python code?

  i = 0  while i < 3:      print(i)      i += 1  else:      print(0)

86) Negative count from the Right.

87) _________immediately terminates the current loop iteration.

88) What will be the output of the following Python code, if s1= {1, 2, 3}?

s1.issubset(s1)

89) Which language is derived from many other language, including ABC, Modula- 3, C, C++, Algol-68, SmallTalk, and Unix shell and other scripting languages.

90) Find the last element of list in Python? Assume 'bikes' is the name of list.

91) _____ returns the current time instant, a floating-point number of seconds since the epoch.

92) What will be the output of the following Python code?

print("Hello {name1} and {name2}".format(name1='foo', name2='bin'))

93) Algorithms cannot be represented by

94) Output data screen

95) Can we write if / else into one line in python?

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

z=set('abc')

  z.add('san')  z.update(set(['p', 'q']))

z

97)
_______ is a group of characters.

98) Which of the following statement will be true.

99) Which of the following functions converts a string to a float in python ?

100) What will be the output of the following Python code?

  1. >>>t = (1, 2, 4, 3, 8, 9)
  2. >>>[t[i] for i in range(0, len(t), 2)]

 

Your score is

You cannot copy content of this page