Merge Leaf labeled trees I have a set of leaf-labeled trees. I want to concatenate them into a single leaf labelled tree in such a way that the height of the resulting tree is smallest possible.
Can somebody please help me to generate an algorithm for this task, 
with good performance? 

Leaf labelled tree is a tree in which all the data is held at leaves.
You can solve this using dynamic programming. Given trees $T_1,\ldots,T_n$, for each $1 \leq a \leq b \leq n$ compute the best way of concatenating $T_a,\ldots,T_b$. Details left to you.