Restarting with a more functional oriented data structure.
Added method to count the number of level in a tree.
Added method to get the minima and maxima.