Re: [algogeeks] print all paths which sum up to a value.

2011-08-25 Thread arjoo kumar
this is C++ programme bool hasSum(struct node **head , int sum){ if ((*head ) == NULL) return (sum == 0) else { sum = sum -*(head)-data; hasSum((*head)-left , int sum); hasSum((*head)-right , int sum) ; } }

Re: [algogeeks] netapp!

2011-08-20 Thread arjoo kumar
HI priya ramesh I want to know that...what is the criteria of netapps in your college On Fri, Aug 19, 2011 at 5:24 AM, priya ramesh love.for.programm...@gmail.com wrote: on what subjects are questions asked in netapp?? (Both written and tech interview) Plz help -- You received this

Re: [algogeeks] how to find median of two sorted arrays

2011-08-18 Thread arjoo kumar
find 1length1 (arr1) 2length 2(arr2) 3sum = length1 +length 2 4loops = sum /2 5... set two pointer (say ptr1 ptr2) on arr[0] arr2[0] 6 start loop for i =1 to loops if (*ptr1 = *ptr2 ) ptr1++ else ptr2++ please manage it

Re: [algogeeks] query

2011-06-29 Thread arjoo kumar
we carefull.. there is no space between / * i.e In question it is written as /*. which denote the behaviour of multiline comment it is not end with */ So this is the error if I m wrong then Please correct me -- You received this message because you are subscribed to the Google Groups

Re: [algogeeks] plz xplain the output

2011-06-16 Thread arjoo kumar
g##g2 means gg2 i,e concat g g2 by the property of #define it is replace where it is called. On Thu, Jun 16, 2011 at 8:36 PM, amit the cool amitthecoo...@gmail.comwrote: #define f(g,g2) g##g2 main() { int var12=100; printf(%d,f(var,12)); } output-100 -- You received this message

Re: [algogeeks] C Output

2011-05-29 Thread arjoo kumar
when u store 0.08 on the float variable a then it does not store exactly 0.08 on 'a' actually it store 0.7999 that's why after comparition it make less quantity with 0.08 i.e 'if ' condition is true and print it HELLO On Sun, May 29, 2011 at 9:21 AM, Ankit Agarwal

Re: [algogeeks] PUZZLE

2011-05-21 Thread arjoo kumar
534 is the correct answer On Fri, May 20, 2011 at 8:47 AM, Bhavesh agrawal agr.bhav...@gmail.comwrote: 1 elephant can take 1000 banana at a time and eat 1 banana after each 1km travel. total bananas are 3000 and distance have to travel from A to B is 1000km. So how many max bananas he can

Re: [algogeeks] Re: FUN TEASER 11 may

2011-05-13 Thread arjoo kumar
good answer On Wed, May 11, 2011 at 8:52 PM, anil chopra anil.chopra2...@gmail.comwrote: i will stop imaging. On Wed, May 11, 2011 at 7:38 PM, Dave dave_and_da...@juno.com wrote: I was on a river boat in Europe, and the emergency drill was to go to the upper deck and wait, high and dry,

Re: [algogeeks] [brain teaser ] Identical Twin Puzzle 19april

2011-04-20 Thread arjoo kumar
date of birth are same but birth's time is different On Tue, Apr 19, 2011 at 1:30 AM, Lavesh Rawat lavesh.ra...@gmail.comwrote: * Identical Twin Puzzle Two women apply for a job. They are identical. They have the same mother, father and birthday. The interviewer asks, 'Are you twins?' to

Re: [algogeeks] Fwd: Fw: Fwd: : PLEASE SIGN AND FORWARD!!! *

2011-03-15 Thread arjoo kumar
arjookumar2009ar...@gmail.com On 3/13/11, Srinivas Baravatula prodi...@gmail.com wrote: -- Forwarded message -- From: ZEAL DECESSUS zealg...@gmail.com Date: Sun, Mar 13, 2011 at 12:15 PM Subject: Fwd: Fw: Fwd: : PLEASE SIGN AND FORWARD!!! * To: Adnan Chowdhury