PYTHON SETS

PYTHON SETS

Professional Development

10 Qs

quiz-placeholder

Similar activities

Trg@home 1

Trg@home 1

Professional Development

10 Qs

Topic Quiz-1 : Python Basics

Topic Quiz-1 : Python Basics

Professional Development

10 Qs

Sains Komputer Tingkatan 4 - 3.1.1 Mengkaji keperluan intera

Sains Komputer Tingkatan 4 - 3.1.1 Mengkaji keperluan intera

1st Grade - Professional Development

10 Qs

Mothers Competition

Mothers Competition

Professional Development

10 Qs

Digitarkade klubi

Digitarkade klubi

Professional Development

12 Qs

sabit ve değişken

sabit ve değişken

KG - Professional Development

10 Qs

Digital Technology Office 365 - 29May2020

Digital Technology Office 365 - 29May2020

University - Professional Development

13 Qs

Email of request

Email of request

12th Grade - Professional Development

11 Qs

PYTHON SETS

PYTHON SETS

Assessment

Quiz

Computers

Professional Development

Practice Problem

Medium

Created by

RAVINDER B

Used 11+ times

FREE Resource

AI

Enhance your content in a minute

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

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which of the following are true for objects of Python’s set type

The order of elements in a set is significant.

A set may contain elements that are mutable.

A given element can’t appear in a set more than once.

Sets are mutable.

2.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which of the following is not the correct syntax for creating a set?

set([[1,2],[3,4]])

set([1,2,2,3,4])

set((1,2,3,4))

{1,2,3,4}

3.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which of the following statements is used to create an empty set?

{}

set()

[]

()

4.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

If a={5,6,7,8}, which of the following statements is false?

print(len(a))

print(min(a))

a.remove(5)

a[2]=45

5.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which of these about a frozenset is not true?

Mutable data type

Allows duplicate values

Data type with unordered values

Immutable data type

6.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Suppose t = (1, 2, 4, 3), which of the following is incorrect?

print(t[3])

t[3] = 45

print(max(t))

print(len(t))

7.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

t = (1, 2)

print(2*t)

(1, 2, 1, 2)

[1, 2, 1, 2]

(1, 1, 2, 2)

[1, 1, 2, 2]

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?