I was going through this problem on stackoverflow, and I found this classic
article on this very topic
http://www.americanscientist.org/issues/pub/2002/3/the-easiest-hard-problem
Definitely, worth a read.
--
*
*
*thanks regards,*
*Avinesh Kumar
National Institute of Technology, Calicut.*
does that means displaying only boundary elements of tree and if yes in
which order ?
*My Answer* :
I think it would be something like doing preorder travesal of left subree
with boundary elements and leaf elements of left subtree + post order
traversal of right subtree with boundary element and
Given an infinite stream of integers with only k distinct integers, find
those distinct integers. How would you modify your solution if k is also
very large and cannot use hash table.
thanks
--mac
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks