You are given various statements regarding some points and the direction between them. Check if all the statements are correct or not.
For example:
P1 is in North of P2
P2 is in North of P3
P3 is in North of P1
Output: False (since P3 will be in South of P1)
Directions can be N,S,W,E,NW,NE,SW, etc.
The interviewer gave the hint to use graph.