

def    _UpperCAmelCase    (					_SCREAMING_SNAKE_CASE   :						list	,				_SCREAMING_SNAKE_CASE   :						int    ):





    """simple docstring"""


    for index, item in enumerate(_SCREAMING_SNAKE_CASE    ):
        if item == target:
            return index
    return -1


def    _UpperCAmelCase    (					_SCREAMING_SNAKE_CASE   :						list	,				_SCREAMING_SNAKE_CASE   :						int	,				_SCREAMING_SNAKE_CASE   :						int	,				_SCREAMING_SNAKE_CASE   :						int    ):





    """simple docstring"""


    if not (0 <= high < len(_SCREAMING_SNAKE_CASE    ) and 0 <= low < len(_SCREAMING_SNAKE_CASE    )):
        raise Exception('Invalid upper or lower bound!'    )
    if high < low:
        return -1
    if sequence[low] == target:
        return low
    if sequence[high] == target:
        return high
    return rec_linear_search(_SCREAMING_SNAKE_CASE	,				low + 1	,				high - 1	,				_SCREAMING_SNAKE_CASE    )


if __name__ == "__main__":
       UpperCamelCase__					: str								=      input("Enter numbers separated by comma:\n").strip()
       UpperCamelCase__					: List[Any]								=      [int(item.strip()) for item in user_input.split(",")]

       UpperCamelCase__					: List[Any]								=      int(input("Enter a single number to be found in the list:\n").strip())
       UpperCamelCase__					: int								=      linear_search(sequence, target)
       if result != -1:
              print(F'linear_search({sequence}, {target}) = {result}')
       else:
              print(F'{target} was not found in {sequence}')





# A Bipartite Graph is a graph whose vertices can be divided into two independent sets,
# U and V such that every edge (u, v) either connects a vertex from U to V or a vertex
# from V to U. In other words, for every edge (u, v), either u belongs to U and v to V,
# or u belongs to V and v to U. We can also say that there is no edge that connects
# vertices of same set.
from queue import Queue


def    _UpperCAmelCase    (					_SCREAMING_SNAKE_CASE   :						List[str]    ):





    """simple docstring"""


    SCREAMING_SNAKE_CASE_													=  Queue()
    SCREAMING_SNAKE_CASE_													=  [False] * len(_SCREAMING_SNAKE_CASE    )
    SCREAMING_SNAKE_CASE_													=  [-1] * len(_SCREAMING_SNAKE_CASE    )

    def bfs():
        while not queue.empty():
            SCREAMING_SNAKE_CASE_													=  queue.get()
            SCREAMING_SNAKE_CASE_													=  True

            for neighbour in graph[u]:
                if neighbour == u:
                    return False

                if color[neighbour] == -1:
                    SCREAMING_SNAKE_CASE_													=  1 - color[u]
                    queue.put(_SCREAMING_SNAKE_CASE    )

                elif color[neighbour] == color[u]:
                    return False

        return True

    for i in range(len(_SCREAMING_SNAKE_CASE    )    ):
        if not visited[i]:
            queue.put(_SCREAMING_SNAKE_CASE    )
            SCREAMING_SNAKE_CASE_													=  0
            if bfs() is False:
                return False

    return True


if __name__ == "__main__":
       # Adjacency List of graph
       print(check_bipartite({0: [1, 3], 1: [0, 2], 2: [1, 3], 3: [0, 2]}))


