Yes, sry abhishek , i didnt see the question carefully.
But this can be done with hash map requiring O(n) space and O(n) time.
Sanjay Kumar
B.Tech Final Year
Department of Computer Engineering
National Institute of Technology Kurukshetra
Kurukshetra - 136119
Haryana, India




On Wed, Aug 17, 2011 at 2:15 AM, Abhishek Yadav <abhishek30.nit...@gmail.com
> wrote:

> Thats right...by doing xor this can't be done...hey sanjay please
> reconsider your answer.
>
> On Aug 17, 2:05 pm, sukran dhawan <sukrandha...@gmail.com> wrote:
> > when u xor nos with odd number of times we will get back the same no.only
> > even occurences will give 0.question is to find the no with even
> >  occurence.how will you find that no?
> >
> >
> >
> > On Tue, Aug 16, 2011 at 1:41 PM, MAC <macatad...@gmail.com> wrote:
> >
> > > Given an array of integers. Each number in the array repeats ODD number
> of
> > > times, but only 1 number repeated for EVEN number of times. Find that
> > > number.
> >
> > > --
> > > thanks
> > > --mac
> >
> > >  --
> > > You wreceived 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.- Hide quoted text -
> >
> > - Show quoted text -
>
> --
> 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.
>
>

-- 
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