Write a function to find the powerset of a given set S. I have already written a
ID: 3630941 • Letter: W
Question
Write a function to find the powerset of a given set S.
I have already written a set class in a previous assignment that works with strings and gives the union, cardinality and allows for elements to inteserted along with checking if something is a member of the set already.
The question I have is how to implement the powerset function given the function prototype of:
Set* powerSet(Set S) with the following available class functions:
setCardinality
insertItem
isMember
setUnion
setIntersection
The function itself should be written recursivly as the size of the set is dynamic, thanks for any insight!
Explanation / Answer
Output :
Sorry This is the Code .Change to your functions accordingly.I am not able because I got Programs on lmy Head ..Please rate Helpfull atleast :)
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.