Question: Question 4 (4 marks] The module SetOfInt is for a set of integers. Please answer the following questions related to making that module generic. a.
![Question 4 (4 marks] The module SetOfInt is for a set](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/09/66f395638464b_52266f39562f114d.jpg)
Question 4 (4 marks] The module SetOfInt is for a set of integers. Please answer the following questions related to making that module generic. a. How would you change the specification to make it generic? (Specifically what changes would you make to the given specification. You don't need to redo the spec, just summarize what changes you would need to make.) b. What changes would you need to make to the Python implementation to make it generic for type T? (Again, you can describe and characterize the changes; you don't actually have to make them.) c. What relational operator needs to be defined for type T to be a valid choice? d. BONUS (1 mark) How would you specify (in the MIS) the relational operator constraint (from the previous question) on the generic type T? [Put your answer below. SS] a. b. c. d. (BONUS)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
