Graph is biparite or not

my code is accepting at leetcode but giving wrong ans at hackerblocks and when i compile so it is giving me MLE error… i think i am doing wrong in taking input …

hello @amaaanahmedkhan987

pls share the hackerblocks link , where u r submiting.
i will check

yes u r taking input in incorrect format.
read this . and make appropriate changes in ur code
image

pls check ur updated code here_>

@aman212yadav

what wrong in this???