Google Interview Question

It was a question on graph