Tarun Oohri wrote:Why is it coming wrong ? Any Guess ??
Yes.
Integer is an
immutable class (ie, you can't change it), so you have to
replace it in your
Map every time you get a repeated
word.
You might find things easier if you use AtomicInteger instead, because you
can update those.
HIH
Winston