Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
6 views

Python-I Second Internal

Uploaded by

rajitha
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

Python-I Second Internal

Uploaded by

rajitha
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

ANNIE BESANT WOMEN’S COLLEGE

BSC ( MSCs & MPCs) (Second Year Third Sem)

SECOND INTERNAL EXAM


SUBJECT: PYTHON-I

NAME : ROLL NUMBER:


Class(Section): Max Marks: 10 M
I. Multiple Choice questions (10 * ½ = 5 m)

1. How to give the definition of a function ___________ [ ]


a) def b) Define c)Def d) None of these
2. How to call this function def BSC():
a)BSc() b)BSC() c) Bsc() d) print(“Hello”) None of these [ ]

3. def BSC():
a=20 ______________ [ ]
a) list b) number c) tuple d) None of these

4. print(“Hello BSC “) gives ______________ [ ]


a) Hello BSC b) Hello BSc c) Hello bsc d) hello bsc

5. print( 2**3) gives ___________ [ ]


a) 8 b) 6 c) 8 and 6 d) None Of these

x, y, z = "Orange", "Banana", "Cherry"


print(x) ---> 6
print(y) ---> 7
6. 6 gives output as [ ]
a)Orange b) Banana c)Cherry d)None of these

7. 7 gives output as [ ]
a)Orange b) Banana c)Cherry d)None of these

for( index in range(____8____, ______9_____, ____10____) )


8. 8 gives _________ [ ]
a) start b)end c) step d) none

9. 9 gives __________ [ ]
a) start b)end c) step d) none

10. 10 gives ________ [ ]


a) start b)end c) step d) none
II. Fill in the blanks (10 * ½ = 5 m)

1. Single Line Comment in python uses _____________________ .


2. x = float(1) print(x) gives ____________
4. The keyword used in elseif condition is ________________.
5. Write some examples of operators are _________________ .
6. Read input an integer value from keyboard _________________.

Check this following program and give the output


num=int(input("Enter any number"))
if num>0:
print(num," is a positive number")
elif num<0:
print(num," is a negative number")
else:
print(num," is neither positive or negative")
7. If I enter num= 8 then it gives ____________
8. If I enter num= 0 then it gives ____________
9. If I enter num= -2 then it gives ____________

a=3
b=1
print(a, b) ----> 9
a, b = b, a
print(a, b) ----> 10

10. 9 gives _____________


11. 10 gives __________________

You might also like