Determining Correctness of Graph