Re: [algogeeks] subarray wid sum=k

2011-09-02 Thread hemank lamba
Are you sure it is not continuous subsets. Because otherwise i guess it is a NP problem. On Fri, Sep 2, 2011 at 7:58 AM, manish kapur manishkapur.n...@gmail.comwrote: given an unsorted array of +ve and -ve elements.find a subarray with sum= k in O(n). you can use some extra space -- You

Re: [algogeeks] subarray wid sum=k

2011-09-02 Thread wujin chen
agree with hemank ! 2011/9/2 hemank lamba hemankla...@gmail.com Are you sure it is not continuous subsets. Because otherwise i guess it is a NP problem. On Fri, Sep 2, 2011 at 7:58 AM, manish kapur manishkapur.n...@gmail.comwrote: given an unsorted array of +ve and -ve elements.find a

Re: [algogeeks] subarray wid sum=k

2011-09-02 Thread manish kapur
u have 2 find a continuous subarray... -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For

[algogeeks] subarray wid sum=k

2011-09-01 Thread manish kapur
given an unsorted array of +ve and -ve elements.find a subarray with sum= k in O(n). you can use some 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 algogeeks@googlegroups.com. To unsubscribe