Design a data structure for History Set with following operations:
- Add(element) : Adds an element to the Set and returns a SequenceId
- Discard(element): Discards an element from the Set and returns a SequenceId
- Member(sequenceId): Return the state of historySet at a given sequenceId
Example:
seq1 = add("a")
seq2 = add("b")
seq3 = add("c")
seq4 = discard("b")
member(seq3) = ("a", "b", "c")
member(seq1) = ("a")
member(seq4) = ("a", "c")
Comments (11)

