@sagar: i read contiguous afterords therefore i deleted my post...
and for ankur's approach
:
original array:20 , -9 , 3 , 1, 5 , 0, -6 , 9
array after addition:20 , 11,14,15,20,20,14,23

now when u hash  second array elements
then u fill find collision at value 14 and 20
this means terms b/w 1st 14 and 2nd 14 adds t0 0.(1,5,0,-6)...
is it clear now?



On Thu, Jul 21, 2011 at 12:22 AM, Kamakshii Aggarwal
<kamakshi...@gmail.com>wrote:

>
> a little mistake in ankur's solution
> 20 , -9 , 3 , 1, 5 , 0, -6 , 9
> 20 , 11,14,15,20,20(instead of 0),14,23
> now if sum of two consecutive terms is same then this means a 0 exists.and
> hence it can be printed as a subarray..else ankur's sol works fine..:)
>
>
> On Thu, Jul 21, 2011 at 12:06 AM, sagar pareek <sagarpar...@gmail.com>wrote:
>
>> @ankur....
>>
>> pls explain through an example by taking above problem.....
>>
>>
>> On Wed, Jul 20, 2011 at 10:52 PM, SAMMM <somnath.nit...@gmail.com> wrote:
>>
>>>
>>>
>>> Nice solution dude .........!!!! Like that one ....
>>>
>>> --
>>> 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 more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>>
>>
>>
>> --
>> **Regards
>> SAGAR PAREEK
>> COMPUTER SCIENCE AND ENGINEERING
>> NIT ALLAHABAD
>>
>>  --
>> 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 more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>
>
> --
> Regards,
> Kamakshi
> kamakshi...@gmail.com
>



-- 
Regards,
Kamakshi
kamakshi...@gmail.com

-- 
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 more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to