; --
> yezhu malai vaasa venkataramana Govinda Govinda
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algoge...@googlegroups.com.
> To unsubscribe from this group, send em
One of my friend ask me this n i am bad in P & C (will love if smone can
provide me a link to learn it though)
nyways prob is:
there are infy color balls of k different color
you are allowed to pick n balls out of those infy(infinite) balls
cond is : you must have all k color balls with u
obvious
; from (a, b) to (c, d) in O(1)
>>
>> for N*N matrix, Complexity is O(N^4)
>>
>> On 28 April 2010 13:36, Ashish Mishra wrote:
>>
>>> you are given a M x N matrix with 0's and 1's
>>> find the matrix with largest number of 1,
>>&
eed to use extra space u have
> to just ditach the node from binary tree and attach it in bst.
>
> On Wed, Apr 28, 2010 at 1:18 AM, Ashish Mishra
> wrote:
> > How to build BST from binary tree in place i.e without extra space ??
> >
> > --
> > You received this
you are given a M x N matrix with 0's and 1's
find the matrix with largest number of 1,
1. find the largest square matrix with 1's
2. Find the largest rectangular matrix with 1's
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this
How to build BST from binary tree in place i.e without extra space ??
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+un
>>> > > "Algorithm Geeks" group.
>>> > >>>> > > To post to this group, send email to
>>> algoge...@googlegroups.com.
>>> > >>>> > > To unsubscribe from this group, send email to
>>> > >>&
ou received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algoge...@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com
>&
y u need backtracking
i think it can be done with DP
On Sat, Apr 10, 2010 at 9:12 AM, «« ÄÑÜJ »» wrote:
> Need help in designing efficient backtracking algorithm for the coin
> changing problem. where a1, a2, an are the set of distinct coins
> types, where each ai is an integer. and each type is
yup atul algo is correct
(cur_data - node->right) * ( cur_data- node->left) < -1 for ancestors
On Thu, Apr 8, 2010 at 10:19 AM, atul verma wrote:
> Its very simple to solve this.
>
> Start from root.
>
> Compare the value of current node data value to both nodes.
>
> 1. if both are greater tha
Can it be done in more or less like merge sort way
i.e 1. divide array into half
2. keep on doing it till u have two element left
3. arrang match between two and return winner
On Wed, Apr 7, 2010 at 12:20 PM, «« ÄÑÜJ »» wrote:
> Can any one help me with this problem
>
>
> Its a divide and co
i think u mean lowest commen ancestor?
On Wed, Apr 7, 2010 at 10:34 PM, Himanshu Aggarwal
wrote:
> For a given binary tree, given the root and two node pointers, how can we
> find their youngest common ancestor.
>
> Say the node is like:
>
> struct node{
>int data;
>struct node*l
@ankur how u can solve it in o(n)
i suppose u need atleast o(n lgn)
On Sun, Sep 6, 2009 at 2:52 PM, ankur aggarwal wrote:
> o(n) is the best sol known to me..
>
>
> On Sun, Sep 6, 2009 at 1:54 PM, Pramod Negi wrote:
>
>> i guess sorting will do the work.
>> any other constraint??
>>
>>
>> On Sun
13 matches
Mail list logo