NEW
Font size
Worksheetspython
Total questions: 20
Worksheet time: 40mins
Which one is not a keyword ?
as
for
in
ask
What are keywords ?
predefined words
key to open python
simple words
none
what does ord() return ?
unicode
ascii code
python code
ford keyword
what did str() do ?
convert into string datatype
convert into list datatype
convert into set datatype
convert into tuple datatype
what is the output of the following code ?
a = “5”
b = 2
c = a+b
print(c)
52
7
10
Type Error
What do you mean by memory address ?
Address of program
Address of memory location
Address of songs
none
what is the output of the following statement ?
print(“apple”+” mango”)
apple
mango
applemango
none
Which of the following are not the strings in python ?
1) “ “ 2) “akansha” 3) “””rohima””” 4) sakshi 5) ‘sarvan” 6) ‘6’
2 and 3
1 and 3
3 and 4
4 and 5
How many keywords are there in python ?
32
33
34
35
what will happen if we convert the type of a float data into integer ?
fraction part removed
integer part removed
no change
Type Error
Which arithmetic operator has highest precedence ?
**
+
-
/
What is the output of the following code ?
print(int(True))
0
True
False
1
What is the output of The following code ?
a = “5”
b = 5
print(a==b)
1
0
True
False
what is the output of the following code ?
a = “5”
b = 2
c = a*b
print(c)
45
55
65
10
What is the output of the following code ?
print( 9>8>5>3>1 )
1
0
True
False
What is the output of following code ?
print(99%3)
33
0
3
99
what is the output of the following statement ?
print(“apple”+” mango”)
apple
mango
applemango
none
what is the output of the following statement ?
print(“apple”*” mango”)
apple
mango
applemango
Type Error
What is the output of the following code ?
a = 5
a +=2
print(a)
10
7
5
3
The operator used to compare two numbers is
=
==
*
none
