Tuples 8

Tuples 8

12th Grade

10 Qs

quiz-placeholder

Similar activities

Food

Food

11th - 12th Grade

15 Qs

String Formatting in Python

String Formatting in Python

12th Grade

10 Qs

Qu'est ce que les animaux mangent?

Qu'est ce que les animaux mangent?

5th Grade - University

14 Qs

Quiz Time

Quiz Time

11th - 12th Grade

15 Qs

recuperacao 1 programação desenvolvimento de sistemas

recuperacao 1 programação desenvolvimento de sistemas

12th Grade

10 Qs

quiz - 7(exceptions and file handling)

quiz - 7(exceptions and file handling)

12th Grade - University

9 Qs

Vegetables

Vegetables

KG - 12th Grade

15 Qs

Tech Buzz R2

Tech Buzz R2

12th Grade

10 Qs

Tuples 8

Tuples 8

Assessment

Quiz

Other

12th Grade

Hard

Created by

Amy Austin

FREE Resource

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct syntax to print the first item in the fruits tuple?

print(fruits.first)

print(fruits[1])

print(first(fruits))

print(fruits[0])

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which method is used to add an item to a set in Python?

.push()

.insert()

.add()

.append()

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you start writing a for loop in Python?

for i in range(5):

for(i=0; i<5; i++)

for i < 5:

foreach i in range(5):

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which function is used to get user input in Python?

getUserInput()

readLine()

input()

scanf()

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you create a variable with the numeric value 5?

x = 5

x = int(5)

int x = 5

x := 5

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is used to create a new list?

<>

[]

{}

()

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you insert 'tomato' at the beginning of a list named 'fruits'?

fruits.insert(1, 'tomato')

fruits.add('tomato')

fruits.insert(0, 'tomato')

fruits.append('tomato', 0)

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?