Added basic deque for reading off the key from either end