Statement
Program
Flow chart
All the above
What will be the output of the following Python code ?
def display(b,n): while n>0: print(b,end='') n=n-1 display('z',3)
zzz
zz
Infinite loop
An exception is thrown
Circle
Parallelogram
Diamond
A static variable
A global variable
A local variable
An automatic variable
A function that calls itself
A function that calls other functions
Both (A) and (B)
None of the above
list1.sum(5)
list1.add(5)
listl.append(5)
list1.addelement(5)
What will be output for the following code ?
import numpy as np
ary=np.array([1,2,3,5,8])
ary=ary+1
print(ary[1])
0
1
2
3
Quick response code
Same format in which the data is held in memory
ASCII format
Unicode format
.py
.pyth
.python
none of these
procedure
function
bug
None of these
Which of the following will delete key-value pair for key="tiger" in dictionary?
dic={"lion":"'wild","tiger":"'wild",'cat":"domestic","dog":"domestic"}
del dic("tiger"]
dic["tiger"].delete()
delete(dic.["tiger'])
del(dic.["tiger"])
What will be the output of the following Python code?
d1={"abc":5,"def":6,"ghi":7} print(d1[0])
abc
5
{"abc":5}
error
try
Brackets
Indentation
Catch
def power(x, y=2): r=1 for i in range(y): r=r*x return r print(power(3)) print(power(3,3))
Option A
Option B
Option C
Option D
colon
comma
semicolon
hyphen
Variable
File
Both of the above
Text file
Binary file
what will be output for the following code?
import numpy as np a=np.array([1,2,3,5,8]) print(a.ndim)
count()
strip()
upper()
उपरोकà¥à¤¤ सà¤à¥€
what is 'f' in the following statement?
f=open("Data.txt","r")
file name
file handle
Mode of file
file handling