Day3 - Python STT

Day3 - Python STT

Professional Development

10 Qs

quiz-placeholder

Similar activities

Scope of Variables in Python

Scope of Variables in Python

1st Grade - Professional Development

15 Qs

Python Training Day-2  Quiz-2

Python Training Day-2 Quiz-2

Professional Development

10 Qs

Python

Python

University - Professional Development

10 Qs

CSI PROJECT 2

CSI PROJECT 2

Professional Development

9 Qs

Python Fundamental 1

Python Fundamental 1

Professional Development

10 Qs

X-Quiz #4

X-Quiz #4

Professional Development

10 Qs

Python Collections

Python Collections

Professional Development

10 Qs

BrightChamps Technical Round - C++ language

BrightChamps Technical Round - C++ language

Professional Development

15 Qs

Day3 - Python STT

Day3 - Python STT

Assessment

Quiz

Computers

Professional Development

Medium

Created by

ICT Academy of Kerala

Used 6+ times

FREE Resource

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which is the correct operator for power(xy)?

X^y

X**y

X^^y

None of the mentioned

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which one of these is floor division?

/

//

%

None of the mentioned

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Suppose d = {“john”:40, “peter”:45}, what happens when we try to retrieve a value using the expression d[“susan”]?

Since “susan” is not a value in the set, Python raises a KeyError exception

It is executed fine and no exception is raised, and it returns None

Since “susan” is not a key in the set, Python raises a KeyError exception

Since “susan” is not a key in the set, Python raises a syntax error

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following statements create a dictionary?

d = {}

d = {“john”:40, “peter”:45}

d = {40:”john”, 45:”peter”}

All of the mentioned

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

The output of the code above is

Key Error

4

Math

6.

MULTIPLE SELECT QUESTION

30 sec • 1 pt

Media Image

Assume the key is the student's id and the value is the grade. Which of the following code will get the grade of student id 102?

grades[102]

grades.get(102)

grades[2]

grades[3]

grades.key(102)

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What is the output of the code above

3.9

4

Syntax error

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?