TikTok Interview Question

Implement a data structure of Deque