Read the instructions carefully before you begin
Which line of code correctly adds an item to the fruits dictionary with a key of ‘grapes’ and a value of 15?
fruits = {'apples': 1, 'bananas': 4, 'pears': 17, 'oranges': 14} What is the output of below code?
print(3-2*2*3+99/11)
Is python code compiled or interpreted?
Part of algorithm which is repeated for fixed number of times is classified as
The function pow(x,y,z) is evaluated as:
________is a data file.
The ________ function returns its argument with a modified shape, whereas the ________ method modifies the array itself.
Series data type can hold ______________.
Which statement will return one line from a file (file object is 'f‟) ?
What will be the output of the following ?
import sys
sys.stdout.write('Welcome\n')
sys.stdout.write('All\n') To read binary files data ___________ function is used.
The _____ mode of Python gives instant result of typed statement.
What will be the output displayed by the instruction, print(String[-3]), if String="Programming and Problem Solving through Python"?
What will be the output of the following pseudocode, where ^ represent XOR operation?
Integer a, b, c
Set b=5,a=1
c=a^b
print c What will be the output of the following Python code?
>>>t1 = (1, 2, 4, 3)
>>>t2 = (1, 2, 3, 4)
>>>t1 < t2 An algorithm represented in the form of programming languages is
if list1=[10,20,30], then operation list1*2 returns _____.
Which of the following expressions will not yield 0.5?
Given a string x=”hello” What is the output of x.count(‘l’) ?
Python supports the creation of anonymous functions at runtime, using a construct called
Which function is used to add an element (5) in the list1 ?
Which of the following will delete the key-value pair for the key "tiger" in the dictionary?
dic = {"lion":"wild", "tiger":"wild", "cat":"domestic", "dog":"domestic"} What task can be performed on python array?
full() function requires 2 arguments minimum to pass in it.
FORTRAN stands for:
Which of the following is not a keyword in Python ?
Which keyword is used to declare a function or method in Python?
sets the size of the buffer used in ufuncs
What is the result of evaluating 2 + 2 ** 3 / 2?
What type of data is :
arr = [(1, 1), (2, 2), (3, 3)]
What will be the output of the following ?
print(sum(1,2,3))
Which of the following mode in file opening statement results or generates an error if the file does not exist?
Each byte of character is stored as its ASCII value in _______
Which of the following executes the programming code line by line?
Which of the following is not a correct mode to open a file?
What is the order of namespaces in which Python looks for an identifier?
Which statement is correct to import all modules from the package?
How do you close a file object (fp)?
What is the output of the following code ?
a = {1: "A", 2: "B", 3: "C"}
b = {4: "D", 5: "E"}
a.update(b)
print(a) If str="Information " then what will be the output: print (str[2:8])
Which function is used to read all the characters?
Which of the following options is correct?
Which of the following error is returned when we try to open a file in read mode which does not exist ?
What happens if no arguments are passed to the seek function?
What is/are technical strength of python ?
What will be the value of the following Python expression?
4+2**5//10
The way for solving a problem step by step is known as __________.
To read the entire remaining contents of the file as a string from a file object infile, we use ____________
Which of the following is a Python tuple?
When we open file in append mode the file pointer is at the _________ of the file.
In seek(), value _______________ sets the reference point at the current file position.
Which module in the python standard library parses options received from the command line?
What does pip stand for python?
What is the output of the following ?
i = 2
while True:
if i%3 == 0:
break
print(i,end=" " )
i += 2
The list of identifiers used in a function call is called
Evaluate the expression (9//4*3-6*3//4)
What is the primary purpose of a flowchart?
A detailed flow chart is called as______?
A program that can execute high-level language programs.
What is ‘f’ in the following statement ?
f=open(“Data.txt”, “r”)
Iteration is the repetition of a
_________ immediately terminates the current loop iteration.
Which of the following characters act as default delimiter in a CSV file?
Which of the following is not a benefit of modular programming?
What will be the output of the following?
import numpy as np
a = np.array([1,5,4,7,8])
a = a + 1
print(a[1]) what is value of this binary no. 101001
In flowchart representation, which of the following symbols indicates input/output?
The full form of CSV is
Function blocks begin with the _______________ .
Output: SMTWTFS [-3:-1]
What is the output of the following ?
x=123
for i in x:
print(i)
Pseudo code is also known as:
What is the output of >>> float('12.6')
The readlines() method returns ____________
What will be the datatype of the var in the below code snippet?
var = 10
print(type(var))
var = "Hello"
print(type(var))
Python '/' operator will always yield the result of operator
What will be the output of the following Python code ?
from math import factorial
print(math.factorial(5))
Which one is not the attribute of a file?
list, tuple, and range are the ___ of Data Types.
What will be the output of the following Python code?
def maximum(x, y):
if x > y:
return x
elif x == y:
return 'The numbers are equal'
else:
return y
print(maximum(2, 3))
for is an _________ controlled loop.
What will be the output of the following Python code?
if (9 < 0) and (0 < -9):
print("hello")
elif (9 > 0) or False:
print("good")
else:
print("bad")
What is the significance of the tell() method?
Which one is used to find the reverse of any list 'L?.
Which of the following methods is used to find the index of a specified element in a tuple in Python?
Point out the incorrect statement:
Which module can be used to convert a Python script into an executable program?
What will be the output of the following Python function?
complex(1+2j)
Which operator has highest precedence?
What will be the output of the following Python code?
sys.stdout.write(' Hello\n')
sys.stdout.write('Python\n')
How do you rename a file?
Which one of these is floor division?
Algorithm and Flowchart used for ______.
What will be the output:
print(7//2)
print(7/2)
What wil be the output: 3*2/+15//7%2
What is the value of x if x = math.ldexp(0.5, 1)?
Determine the output:
for i in range(20, 30, 10) :
j=i/2
print(j)
What is the output of this expression?
3*1**3 What is the maximum possible length of an identifier?
Which of the following data types is not supported in python?
Thanks, Candidate! Your responses have been recorded.
Hook this screen up to your backend to show the actual score.