-- Final Argorithm

mincostTree  ::  [Int] -> Tree
mincostTree  =   foldl1 Fork . map snd . foldrn insert (wrap . leaf)
mincostTree  ::  [Int] -> Tree
mincostTree  =   foldl1 Fork . map snd . foldrn insert (wrap . leaf)
mincostTree  =   foldl1 Fork . map snd . foldrn insert (wrap . leaf)