Given a list of structs which include two ids of parent node and the associated child node, construct a tree.
Sigiloso
The solution should use O(n) time and O(n) space. The idea is to hash ids (parent id - child id). The the linear scan constructs the tree.