Generic Types and Methods
- slide 2 : 21
Operations on sets
We will use the class
Set
as the motivating example in this lecture
Set
operations
aSet
.
Member
(
element
)
aSet
.
Insert
(
element
)
aSet
.
Delete
(
element
)
aSet
.
Count
aSet
.
Subset
(
anotherSet
)
aSet
.
GetEnumerator
()
aSet
.
Intersection
(
anotherSet
)
aSet
.
Union
(
anotherSet
)
aSet
.
Diff
(
anotherSet
)