A deque stands for Double-Ended Queue. It is a special type of data structure that allows you to add and remove elements from both ends efficiently. This makes it useful in applications like task scheduling, sliding window problems and real-time data processing.
from collections import deque
# Declaring deque
de = deque(['name','age','DOB'])
print(de)
Output
deque(['name', 'age', 'DOB'])