cbse cs logo


Function in Python

MCQ on Function set 1


1 A .py file containing constrants/variables, classes, functions etc. related to a particular task and can be used in other programs is called____

ANSWER= A)module


2 The collection of modules and packages that together cater to a specific type of applications or requirements, is called______

ANSWER= B) library


3 An independent triple quoted string given inside a module, containing documentation related information is a_____

ANSWER= B) dstring


4 The help statement display ___ from a module.

ANSWER= D) docstrings


5 Which command(s) modifies the current namespace with the imported object name?

ANSWER= C) from import object


6 Which command create a separate namespace for each of the imported module?

ANSWER= B) import module


7 Which of the following random module function generates an integer?

ANSWER= A)random( ),C)uniform( )


8 Which of the following random module functions generates an integer?

ANSWER= B) randint( )


9 Which file must be a part of a folder to be used as a Python package?



10 A python module has____ extension.

ANSWER= C) .py

Click the button to see more MCQ

error: Content is protected !!