@giri:
can u post d correct answer??
--
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+unsubscr...@googlegroups.com.
For
@giri:
thnx frnd...sorry ppl . ignore my post :(
--
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+unsubscr...@googlegrou
for the above post i have assumed that the two nodes whose sum is k is
present in the BST...
so correct me if m wrong
--
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 unsubsc
can v do like this???
findnodes(root,sum)
{
if(root==abs(sum-root->data))
print (the data is root->data, sum-(root->data));
else
if(rootdata))
findnodes(root->right,sum-root->data)
else if(root>abs(sum-root->data))
findnodes(root->left,sum-root->data)
else if(root->left==NULL || root->right==NULL
hw abt this?
start from right most bit..
if it is the right most bit and if its 0 then flip it and proceed to
the prev. bit
else
flip the rightmost zero to 1 and invert the subsequent bits
follow the above proc. till the left most bit is flipped to 1.
correct me if m wrong!!
--
You received
@raj
really cool
On Aug 22, 1:08 pm, Raj N wrote:
> Generate all binary strings of length k. For eg: S={1,2,3,4,5} generate all
> binary strings of length 5. 0 represents that particular number is absent
> and 1 for the presence of the number.
>
>
>
> On Fri, Aug 13, 2010 at 11:35 PM, asdf wro
read the i/p file
count the no. of '\n' characters
if count > k (argument of tail) then print all chars till EOF
correct me if m wrong !!!
On Aug 16, 9:16 am, vikas kumar wrote:
> the method of farword seek is inefficient. consider case of 10
> lines and you want to display only 3-4 lines. b
link nt working...so can anyone explain fr new users??
On Aug 16, 6:52 pm, Minotauraus wrote:
> Please check link.
>
> On Aug 15, 8:25 pm, Gene wrote:
>
>
>
> >http://groups.google.com/group/algogeeks/browse_thread/thread/f56bac6...
>
> > The best solution given there is O(n) with only constant
can anyone post a good article on tries??? i am a newbie...so pls
help!!
On Aug 22, 11:26 am, Ukil wrote:
> use suffix trie.
>
> On Aug 16, 9:36 pm, ashita dadlani wrote:
>
>
>
> > You have a string say "foobarfoo" in which "fo" and "oo" aree repeated
> > twice.You have to find all such repeated
if the file is standard i/p then go for strings or linked list.
On Aug 16, 10:44 am, janani thiru wrote:
> How can I read a file which has 10^9 characters or more efficiently?
>
> --
> Janani T
--
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group
@asutosh::
all ur efforts 2 write some code wud be worthless if it cant work for
some inputs...if it can , then no one does bother about time
complexity.
since it doesn for large i/ps v hav 2 write some efficient code
(although i agree wid u dat its painful :P )
On Aug 17, 9:45 pm, Dave wro
@manohar and @giri::
doesn recursion itself use stacks( implicitly)??
On Aug 18, 9:26 pm, Giri wrote:
> @manohar: thnks man.. this solution would be apt..
>
> if there's any better algo which doesn't use an extra stack or queue,
> but does the purpose in recursion, do post it..
>
> On Aug 18, 8
12 matches
Mail list logo