Checking If A Graph Is Bipartite