wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Internship on "ML & DL using Python"

Total questions: 35

Worksheet time: 18mins

Name
Class
Date
1.

What would be the output?

animals = ["Zebra", "Elephant", "Lion", "Tiger"]

print (animals [-1])

a)

Zebra

b)

Elephant

c)

Lion

d)

Tiger

2.

Identify the type of data structure.

s = ( )

a)

List

b)

Tuple

c)

Dictionary

d)

String

3.

What will be the output?

list1 = 'tuple'

print (type(list1))

a)

list

b)

tuple

c)

str

d)

dict

4.

What will be the output?

str1 = "DEPARTMENT"

print (str1 [15])

a)

DEPARTMENT

b)

DEPT

c)

Index Error

d)

" "

5.

CNN stands for ------------------------

a)

Computer Neural Network

b)

Central Neural Network

c)

Convolutional Node Network

d)

Convolutional Neural Network

6.

In RNN, data present in the form of Time Series.

a)

True

b)

False

7.

Which symbols are used to open and close a dictionary?

a)

( )

b)

[ ]

c)

< >

d)

{ }

8.

What would be the output?

list1 = [“apple”, “grape”, “orange”, “watermelon”]

list1.append("Kiwi")

print (list1)

a)

['apple', 'grape', 'orange', 'watermelon']

b)

['apple', 'grape', 'orange', 'watermelon', 'Kiwi']

c)

['Kiwi', 'apple', 'grape', 'orange', 'watermelon']

d)

Error

9.

What will be the output?

d = 10 != 11

print (d)

a)

10

b)

11

c)

True

d)

False

10.

Identify the arithmetic operator which is used to calculate remainder of the division.

a)

#

b)

%

c)

**

d)

//

11.

Identify the sentences which are correct.

1. Tuples in Python are immutable

2. Lists in Python are mutable

a)

1 is correct

b)

2 is correct

c)

Both 1 and 2 are correct

d)

1 is correct, 2 is wrong

12.

In CNN, ______ layer is represented in the form of arrays of pixel values.

 

a)

Input Layer

b)

Output Layer

c)

Pixel Layer

d)

Hidden Layer

13.

Identify the different pooling layers which are present in CNN.

a)

Max Pooling

b)

Sum Pooling

c)

Pixel Pooling

d)

Average Pooling

14.

What would be the output?

colors = ["red", "green", "white", "blue"]

print (type(colors))

a)

("red", "green", "white", "blue")

b)

<class 'tuple'>

c)

<class 'dict'>

d)

<class 'list'>

15.

What will be the output?

print (15//6)

a)

2.5

b)

2

c)

1

d)

1.5

16.

What will be the output?

str5 = "Neurons.123"

print (len(str5))

a)

10

b)

11

c)

12

d)

9

17.

In CNN, _________ layer is used for converting the data into a 1-dimensional array for inputting it to the next layer.

 

a)

Input

b)

Pooling

c)

Flattening

d)

Convolution

18.

Choose the correct output of the following code.

for i in range(0,5,3):

print (i)

a)

0

1

2

3

b)

0

2

4

c)

0

3

d)

0

3

5

19.

What will be the output?

a = 5

b = 2

print (a**b)

a)

5*2

b)

5

c)

10

d)

25

20.

In data visualization, ____ function is used to find number of rows and columns.

a)

pandas

b)

shape

c)

size

d)

numpy

21.

In matplotlib, -------- is used to label x-axis.

a)

labelx

b)

xlabel

c)

xlebel

d)

title

22.

In matplotlib, ---------- is used to display only grid lines for the x-axis:

a)

grid(axis = 'x')

b)

grid('x')

c)

grid(axis = 'y')

d)

gridx()

23.

iloc stands for ---------

a)

instant location

b)

image location

c)

integer location

d)

integration location

24.

Which of the following features are related to Python programming?

1. Dynamically typed

2. Python works only on Linux

3. Non-portable

a)

1 and 2

b)

only 2

c)

1 and 3

d)

only 1

25.

What will be the output ?

print (type(3.5 // 2))

a)

1.0

b)

1.75

c)

<class 'int'>

d)

<class 'float'>

26.

In python, pip stands for __________

a)

performance installer python

b)

preferred installer program

c)

processing installer program

d)

python installer program

27.

In OpenCV, for BGR, we pass a tuple (0, 255, 0) for _____ color.

a)

Red

b)

Blue

c)

Green

d)

White

28.

What is the use of barh( ) function?

a)

To plot scatter graph

b)

To plot vertical bar graph

c)

To plot horizontal bar graph

d)

To plot pie graph

29.

----- function is used to give super titles in subplots.

a)

title( )

b)

supertitle( )

c)

super.title()

d)

suptitle()

30.

What is the output of the following code?

print (type("cv2.imshow"))

a)

cv2.imshow

b)

It displays the image onto the screen.

c)

<class 'str'>

d)

<class 'cv2'>

31.

What will be the output ?

a1 = 1

b1 = 1

print ("a1 + b1")

a)

1 1

b)

2

c)

a1 + b1

d)

Error

32.

What will be the output ?

s1 = "Hello"

s2 = "\tGanesh"

print (s1 + s2)

a)

Hello\tGanesh

b)

HelloGanesh

c)

Hello Ganesh

d)

Hello

Ganesh

33.

a1 = 1

b1 = 0

list1 = a1 * b1

print (list1)

a)

1

b)

0

c)

[ 1, 0]

d)

1 0

34.

numpy stands for _______

a)

Numbered Program

b)

Numerator Python

c)

Numerical Python

d)

Numerical Program

35.

In data visualization, ______ is used to find data type of each variable.

a)

datatypes

b)

dtypes

c)

types

d)

iloc