def xor(a, b):
    """
    exclusive or; a or b, but not both

    >>> xor(1, 0)
    1
    >>> xor(0, 1)
    1
    >>> xor(1, 1)
    0
    >>> xor(0, 0)
    0
    """
    return int((a or b) and not (a and b))