Cloudera Interview Question

Graph problem