<filename>data_structures/stack/remove_duplicates_adjacent.py
def remove(s):
    stack = []
    for element in s:
        if stack and element == stack[-1]:
            stack.pop()
        else:
            stack.append(element)
    

<filename>data_structures/stack/remove_duplicates_adjacent.py
def remove(s):
    stack = []
    for element in s:
        if stack and element == stack[-1]:
            stack.pop()
        else:
            stack.append(element)
    
