Update #2: deque template