Python for Data Science (3150713) MCQs

MCQs of Overview of Python and Data Structures

Showing 11 to 17 out of 17 Questions
11.

String in python is ......

(a)

immutable

(b)

static

(c)

final

(d)

mutable

Answer:

Option (a)

12.

what will be the output of below script

(a)

h

(b)

error

(c)

s

(d)

shan

Answer:

Option (a)

13.

which one of these is not a function of string in python

(a)

len

(b)

count

(c)

title

(d)

find

Answer:

Option (a)

14.

List in python represented with

(a)

curly brackets {}

(b)

square brackets []

(c)

round brackets ()

(d)

double round brackets (())

Answer:

Option (b)

15.

which method will return list of tuples for each key value pair associated with the Dictionary. 

(a)

keys

(b)

values

(c)

items

(d)

keyValues

Answer:

Option (c)

16.

which arithmetic operatos does not supported in python?

(a)

++

(b)

**

(c)

/

(d)

%

Answer:

Option (a)

17.

what is the correct syntax to create user defined functions in python

(a)

def function_name() :

    #code to execute when function is called

(b)

function function_name() :

    #code to execute when function is called

(c)

void function_name() :

    #code to execute when function is called

(d)

function void function_name() :

    #code to execute when function is called

Answer:

Option (a)

Showing 11 to 17 out of 17 Questions