<commit_before>"""Implement a double ended queue."""
from dll import DLL


class Deque(object):
    """Define the Deque class.

    It is important to note that the "tail" of our Deques is actually the front of the Deque.

    __init__(): initializes the Deque class as a composite of the DLL class.
    enqueue(): uses the push method from DLL to add nodes to the end of the Deque.
    dequeue(): removes a node from the front of the dequeue
    peek(): Looks at the front value of the Deque without removing it or advancing the view beyond it.
    size(): returns the size of the Deque.
    """

    def __init__(self, iterable=None):
        """Initiate the Deque as an instance of DLL."""
        self._container = DLL(iterable)

    def append(self, val):
        """Add value to the Deque at the end."""
        self._container.push(val)

    def appendleft(self, val):
        """Add value to the Deque at the beginning."""
        self._container.append(val)

    def popleft(self):
        """Remove the first value of the Deque."""
        return self._container.shift()

    def pop(self):<commit_msg>update docstring for class<commit_after>"""Implement a double ended queue."""
from dll import DLL


class Deque(object):
    """Define the Deque class.

    It is important to note that the "tail" of our Deques is actually the front of the Deque.

    __init__(): initializes the Deque class as a composite of the DLL class.
    append(): uses the push method from DLL to add nodes to the end of the Deque.
    appendleft(): uses the append method from DLL to add nodes to the start of the Deque.
    popleft(): removes a node from the front of the dequeue
    pop(): removes a node from the end of the dequeue
    peek(): Looks at the front value of the Deque without removing it or advancing the view beyond it.
    peekleft(): Looks at the end value of the Deque without removing it or advancing the view before it.
    size(): returns the size of the Deque.
    """

    def __init__(self, iterable=None):
        """Initiate the Deque as an instance of DLL."""
        self._container = DLL(iterable)

    def append(self, val):
        """Add value to the Deque at the end."""
        self._container.push(val)

    def appendleft(self, val):
        """Add value to the Deque at the beginning."""
        self._container.append(val)

    def popleft(self):
        """Remove the first value of the Deque."""
        return self._container.shift()

    def pop(self):
{'fraction_non_alphanumeric': 0.08893360160965795, 'fraction_numerical': 0.0, 'mean_word_length': 2.872274143302181, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '449509', 'n_tokens_mistral': 725, 'n_tokens_neox': 665, 'n_words': 338}