Remember these three things to avoid getting caught in errors and losing scores


#1
  1. E contains undirected edge.
  2. B contains directed edge.
  3. E[i][0] or E[i][1] can be greater than A.

#2

No both E and B contains undirected edges


#3

It’s already given in the problem statement that B contains directed edges.
“All roads are one way ie they go from B[i][0] to B[i][1].”