0 of 9 questions completed
Questions:
You have already completed the quiz before. Hence you can not start it again.
Quiz is loading…
You must sign in or sign up to start the quiz.
You must first complete the following:
Your time:
Time has elapsed
Good work attempting the practice problems!
Please leave a comment below if you require any clarifications or send an email to [email protected] if you have any comments about this quiz.
You have completed this lesson!
Write a Python program to create a tuple with different data types?
(Create a tuple that contains an int, a float, a string).
This response will be reviewed and graded after submission.
Write a Python program to create a tuple with numbers and print one item?
This response will be reviewed and graded after submission.
Write a Python program to print two elements : the 4th element by index from the starting and the 4th element from end of a tuple?
Given tuplex = (“y”, “o”, “u”, “r”, “w”, “o”, “r”, “d”)
This response will be reviewed and graded after submission.
Write a Python program to find how many times the value “4” is repeated in a tuple?
Given: tuplex = 2, 4, 5, 6, 2, 3, 4, 4, 7
This response will be reviewed and graded after submission.
Write a Python program to check whether an element exists within a tuple?
Given tuplex = (“y”, “o”, “u”, “r”, “w”, “o”, “r”, “d”), find whether “r” exists in it.
This response will be reviewed and graded after submission.
Write a Python program to remove an item from a tuple?
Given tuplex = “y”, “o”, “u”, “r”, “w”, “o”, “r”, “d”
can you remove “r” from it?
This response will be reviewed and graded after submission.
Write a Python program to find the length of a tuple?
Create a tuple from “Bacon and Eggs”
This response will be reviewed and graded after submission.
Write a Python program to reverse a tuple?
This response will be reviewed and graded after submission.
Write a Python program to remove an empty tuple(s) from a list of tuples?
You may use the following list:
L = [(), (), (‘a’, ‘b’), (‘a’, ‘b’, ‘c’), (‘d’)]
This response will be reviewed and graded after submission.