Question: Write a Python function check_subset() that takes in two Python lists, representing sets of integers, AA and BB. Your function should return a single Boolean

Write a Python function check_subset() that takes in two Python lists, representing sets of integers, AA and BB. Your function should return a single Boolean (True or False) for whether or not either set is a subset of the other. AA and BB are sets, and not necessarily non-empty.

For example:

Test Result
A = [0, 2, 10, -5] B = [-5, 10] print(check_subset(A, B))
True
A = [0, 2, 4, 6] B = [1] print(check_subset(A, B))
False
A = [] B = [1,2,3] print(check_subset(A, B))
True

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!