0% found this document useful (0 votes)
31 views2 pages

Fycs 1

This document contains a 13 question term test on Python fundamentals. It covers topics like Python flavors, features, data types, operators, variables, lists, sets, loops, and conditional statements. It includes multiple choice and short answer questions to test understanding of basic Python concepts. There are also questions asking to perform set operations and check number divisibility using Python code.

Uploaded by

Shreya Yadav
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
31 views2 pages

Fycs 1

This document contains a 13 question term test on Python fundamentals. It covers topics like Python flavors, features, data types, operators, variables, lists, sets, loops, and conditional statements. It includes multiple choice and short answer questions to test understanding of basic Python concepts. There are also questions asking to perform set operations and check number divisibility using Python code.

Uploaded by

Shreya Yadav
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

TERM TEST-1

Marks=13*1

Q.1 which among is python flavour?

a) Jython b) Silverpython c) PyPy d) IronPython

Q.2 which of the following is not the features of python?

a) user friendly b) free c) Platform dependent d) open source

Q.3 extension of python script is

a) .pt b) .ph c) .py d) .po

Q.4 multiline comment is represented by……. In python.

a) // b) # c) /* d)’’’ ‘’’

Q.5 which is valid variable name in python?

a) _123var b) 123var c) var 123 d) print

Q.6 which is not a valid data type in python?

a) real b) string c) bool d) complex

Q.7 which is keyword in python?

a) False b) float c) True d) while

Q.8 which among the following is mutable?

a) list b) tuple c) string d) number

Q.9 which symbol is used for repetition in python?

a) + b) % c) $ d) *

Q.10 what is the index value of 2 in list [1,2,3,4,5,6] ?

a) 0 b) 1 c) 2 d) 3

Q.11 which of the following is not a special character in string?

a) \p b) \n c) \t d) \\

Q.12 which is incorrect assignment in python?

a) a=10 b) a, b=10,20 c) a==10 d) a=b=c=10

Q.13 which function is used for giving output to the users?

a) output b) input c) print d) else

Marks= 6*1:

var=” introduction to python programming”


what will be the output of:

1) var[5]

2) var[2:6]

3) var[-3]

4) var[-8:-2]

5) var[5:]

6) var[:-2]

Marks=3*1:

list=[1,2,3,4,5] list1=[6,7]

What will be the output of following instruction

1) print(list+list1)

2) list[2]=78

Print(list)

3)print(list*3)

Marks=5 each:

Q.13 set1={1,2,4,3,5,6,1,2} and set2={3,4,5,6,7,7,8} perform union, intersection, difference,


symmetric difference on 2 given sets with the help of python programming and write its output.

Q.14 set1={11,12,41,31,15,61,1,2} and set2={31,41,5,61,7,7,8} perform union, intersection,


difference, symmetric difference on 2 given sets with the help of python programming and write its
output.

Q.15 take a number as input from user and check weather the number is divisible by 3 or not using
python if…else condition.

Q.16 what is variable? what are the rules for declaring a variable?

Q.17 Explain the features of python.

Q.18 what is the difference between python and C.

Q.19 what is the difference between python and JAVA.

Q.20 write a python program to print all odd numbers between (1-10) either using for and while
loop.

Q.21 write a python program to print all even numbers between (1-10) either using for and while
loop.

You might also like