Q22Multiple correct3 Marks24 Dec 2023
L is a list of tuples. Each tuple is of the form `(name, age)`. Select all snippets of code that create a list `names` that contains the names of people whose age is above 45. A sample list `L` and the expected output is given below. You can assume that `L` is already available to you.
Sample Input:
L = [('Ajay', 48), ('Anita', 50), ('Alfred', 39), ('Ahmed', 38), ('Afnan', 38), ('Ananya', 50)]
Sample Output:
['Ajay', 'Anita', 'Ananya']