Question: Q13. Write a Python program that includes the following functions: I A) A function that finds the repeated items of a tuple. Sample tuple/Input: (2,
Q13. Write a Python program that includes the following functions: I A) A function that finds the repeated items of a tuple. Sample tuple/Input: (2, 4, 5, 6, 2, 3, 4, 4, 7) Function returns: 3 B) A function that find the second largest number in a list. Sample List/Input: [1, 1, 1, 0, 0, 0, 2, -2, -21 Output: 1 Sample List/Input: [2,2] Output: None C) A function that removes duplicates from a list. Sample List/Input: 110,20,30,20,10,50,60, 40, 80,50,40] Output: (40, 10, 80, 50, 20, 60, 30] D) A function that counts the number of elements in a list within a specified range. Sample List/Input: (10,20,30, 40, 40, 40,70,80,991, range= 40,100 Output: 6
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
