Revision and Extended Learning for  Lab 1

Revision and Extended Learning for Lab 1

University

26 Qs

quiz-placeholder

Similar activities

Router Quiz for the Layer 3 connoisseur

Router Quiz for the Layer 3 connoisseur

University

22 Qs

ITCC 113 Chapter 9 - Value Returning Functions

ITCC 113 Chapter 9 - Value Returning Functions

University

21 Qs

Anime

Anime

5th Grade - Professional Development

21 Qs

Quiz on Operating System Basics

Quiz on Operating System Basics

University

25 Qs

2.7 System Software

2.7 System Software

12th Grade - University

25 Qs

Examen Ordinario FM/QB

Examen Ordinario FM/QB

University

22 Qs

Multiverse of Computers

Multiverse of Computers

4th Grade - Professional Development

22 Qs

R E V I E W E R

R E V I E W E R

University

25 Qs

Revision and Extended Learning for  Lab 1

Revision and Extended Learning for Lab 1

Assessment

Quiz

Computers

University

Practice Problem

Medium

Created by

Careene McCallum

Used 2+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

26 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

What TYPE of value is stored in the variable num?

Integer

Float

String

Boolean

2.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

What will be the value of ans if num is 12?

4.0

4

4.33

TypeError: unsupported operand type(s) for /: 'str' and 'int'

3.

MULTIPLE SELECT QUESTION

1 min • 1 pt

Media Image

What correction should be made to line 2 to ensure proper execution? NB: There are TWO possible answers.

ans = float(num) /3

ans = num(float) / 3

ans = f"{float(num) / 3}"

ans = f"(float(num) / 3)"

4.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

What value is printed if the user enters 12?

TypeError: unsupported operand type(s) for /: 'str' and 'int'

4.33

4

4.0

5.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

What is the data type of formatted_num?

str

int

float

6.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

What is the data type for formatted_num?

str

int

float

7.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

What is the purpose of :d in the f-string?

It ensures that the variable num_items is treated as an integer when formatting the output.

It formats the number as a string.

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?