add two more solutions: populating tree node, remove duplicates from list