Implemented Deque.