This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

HashSet and LinkedHashSet

 
sura watthana
Ranch Hand
Posts: 77
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
could somebody please tell me what is a HashSet and LinkedHashSet for?
and are they included in the SCJP 1.4 exam?

Thanks

Sura
 
marc weber
Sheriff
Posts: 11343
Java Mac Safari
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For the 1.4 exam, you need to be familiar with Collections (Sets and Lists) and Maps.

See Sun's 1.4 requirements:
http://suned.sun.com/US/catalog/courses/CX-310-035.html

See this Tutorial on Collections and Maps:
http://java.sun.com/docs/books/tutorial/collections/index.html

With respect to HashSet and LinkedHashSet, you basically need to understand that these are Sets (no duplicates); and the LinkedHashSet maintains element insertion order, while the HashSet maintains its own internal ordering. (A TreeSet maintains "natural ordering" of elements.)

See the following with respect to implementation:
http://java.sun.com/docs/books/tutorial/collections/implementations/general.html
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic