[algogeeks] How to find two missing numbers from an unsorted continuous natural numbers array [only use O(1) space and O(n) time]

2010-08-12 Thread vijay
How to find two missing numbers from an unsorted continuous natural numbers array [only use O(1) space and O(n) time] -- 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

Re: [algogeeks] How to find two missing numbers from an unsorted continuous natural numbers array [only use O(1) space and O(n) time]

2010-08-12 Thread ashish agarwal
take the sum of array and product. if they were present then sum will be n(n-1)/2 and product will be n!. make two eq of a+b and a-b with these values and get the num On Thu, Aug 12, 2010 at 5:26 AM, vijay auvija...@gmail.com wrote: How to find two missing numbers from an unsorted continuous