Lecture overview -- Keyboard shortcut: 'u'  Previous page: Motivation for Generic Types [Section] -- Keyboard shortcut: 'p'  Next page: The classes IntSet and StringSet -- Keyboard shortcut: 'n'  Lecture notes - all slides and notes together  slide -- Keyboard shortcut: 't'  Textbook -- Keyboard shortcut: 'v'  Help page about these notes  Alphabetic index  Course home  Page 2 : 21
Object-oriented Programming in C#
Generic Types and Methods
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)