You are given a network of directed graph of N vertices and M edges, where every edges' capacity is 1. An ordered pair (u,v),u≠v is good, if the maxflow is exactly 1 upon setting u as the source vertex and v as the sink vertex of the flow network. Find out if all of the ordered pairs (u,v),u≠v are good or not.
Note
Input format
Output format
Print T lines- i-th line contains answer for i-th testcase. For a testcase, the answer is "Yes" if every ordered pair is good, "No" otherwise.
Constraints
First testcase:
maxflow(2→3)=maxflow(1→2)=1, but,maxflow(3→1)=maxflow(3→2)=maxflow(2→1)=0,maxflow(1→3)=2
Second testcase:
All ordered pairs' maxflow is 1.