The document describes an implementation of two interfaces - ExamPeekableQueue and ExamImmutableQueue. For ExamPeekableQueue, two approaches are discussed - Approach 1 maintains a sorted list and uses binary search for operations in O(lgN) amortized time. Approach 2 uses two TreeSets to partition the elements for O(lgN) enqueue and dequeue. For ExamImmutableQueue, elements are permanently added to the queue. Enqueue and dequeue return new queues in O(1) amortized time by appending/moving elements between two pointer lists, maintaining the original queues.