Re: [algogeeks] Re: Lop in Linked List

2010-10-11 Thread Krishan Malik
HEAD--->x-->y-->z--->5--->6--->7>2--->4--- ^ | |LOOP| --- -Sri On Sun, Oct 10, 2010 a

Re: [algogeeks] unique number in an array

2010-06-15 Thread Krishan Malik
Priyanka, will XOR work for {1,1,1,3,3,4,5} Thanks Sri On Mon, Jun 14, 2010 at 7:02 PM, Priyanka Chatterjee wrote: > > XOR all the elements of array, the remaining value is the required unique > number. > (XORing two same numbers results in zero) >> > > > > -- > Thanks & Regards, > Priyanka Ch

Re: [algogeeks] missing integers in an unsorted array

2010-01-31 Thread Krishan Malik
sum of first N numbers is n(n+1)/2 . take the sum of given numbers and subtract it from n(n+1)/2. Thanks Sri On Mon, Feb 1, 2010 at 4:24 AM, Banoo wrote: > hi, > can you help me solve the following problem? > > You are given an unsorted list of n-1 distinct integers from the range > 1 to n. Wri