Hi,
A binary tree is given we need to print vertical sums of nodes. for
example
1 2 3 4 5
| | 5 | |
| | / | \ | |
| | / | 8 |
| | / | / | \|
| 4 | / | 10
| / | \ 9 | |
| / | \ | |
7 | 6 |
| | | | |
| | | | |
-----------------------------------------------
7 4 20 8 10
Here we need to print sum 7,4,20,8,10.
-Thanks
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/algogeeks?hl=en.