Set in Java
SET IN JAVA ( Belongs to Collection API) – import java.utils.*;
Set is used to hold multiple data.
Can hold only unique data
Can hold max 1 null
Implements Collection interface
By default set can hold any type of data
3 type of Set
HASH set :: Elements are not ordered , fast
Tree Set :: Elements are in sorted ordered, slow
LinkedSet "" Between of Hash and Tree, elements are ordered and fast as well
Subscribe to:
Post Comments
(
Atom
)
No comments :
Post a Comment