Veeva Systems interview question

Construct a tree from a string format