There are $$$4$$$ types of robots:
- A: Can move only down and right. That is, a robot at point $$$(x, y)$$$ can move to point $$$(x + 1, y)$$$ or $$$(x, y + 1)$$$.
- B: Can move only down and left. That is, a robot at point $$$(x, y)$$$ can move to point $$$(x + 1, y)$$$ or $$$(x, y - 1)$$$.
- C: Can move only up and right. That is, a robot at point $$$(x, y)$$$ can move to point $$$(x - 1, y)$$$ or $$$(x, y + 1)$$$.
- D: Can move only up and left. That is, a robot at point $$$(x, y)$$$ can move to point $$$(x - 1, y)$$$ or $$$(x, y - 1)$$$.
There are $$$2$$$ types of cells in the grid:
- . (Empty): A robot can be freely placed and move through empty cells.
- # (Blocked): A robot cannot move to blocked cells.
Given a value $$$N$$$, construct a grid of size $$$(N + 1) \times (N + 1)$$$ such that each cell is either empty or blocked. Then place $$$N$$$ robots of any type you want. Robots should be placed in empty cells, and no two robots should be placed in the same cell.
You are also given a tree, where each non-leaf vertex has at least 4 neighbours. Let $$$E$$$ be the set of edges ($$$x_i, y_i$$$). Let $$$S_i$$$ be the set of cells to which robot $$$i$$$ can move. The following conditions should be satisfied:
- For all pairs $$$(i, j) \in E$$$, $$$S_i \cap S_j \neq \emptyset$$$ must hold.
- For all pairs $$$(i, j) \notin E$$$, $$$S_i \cap S_j = \emptyset$$$ must hold.