Implement a generic tree Node class | Microsoft Interview Question