Question: Given the user inputs, complete a program that does the following tasks: Define a set, fruits, containing the user inputs myFruit 1 , myFruit 2

Given the user inputs, complete a program that does the following tasks:
Define a set, fruits, containing the user inputs myFruit1, myFruit2, and myFruit3.
Add the user input theirFruit to fruits.
Find the intersection of fruits and yourFruit1 and yourFruit2
Remove myFruit1 from fruits.
Note: For testing purposes, sets are printed using sorted() for comparison.
Ex: If the input is:
apple
peach
lemon
apple
pear
plum

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!