File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Code to get list of duplicate elements from ArrayList

 
Krishna Tota
Ranch Hand
Posts: 40
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I knnow that in list interface we can store duplicate elements by using method like

void add(int index,Object obj).

I want the code for rettriving only the duplicate elements from the list.

Please give the code for this


Thanks,
Krishna
 
Joanne Neal
Rancher
Pie
Posts: 3742
16
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Krishna Tota:
Please give the code for this


Why don't you show us what you have tried so far. You won't learn as well if we just give you the answer.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic