collections framework Flashcards
—– is immutable
—— Is mutable, threadsafe and slower.
——– is mutable,faster, and not threadsafe
String
Stringbuffer
Stringbuilder
A collection of iterables that contain and manipulate a group of objects
The collections Frameworks
———- is similar to an array but it deals only with objects, they can grow in size
The collection framwork
what is included in the collections framework
What is not iterable or part of the collections framework
lists
sets
queues
Maps
Ordered collection, has an index and can have duplicates and null values.
Lists
unique element that don’t have a particular order
Sets
Collection that operates on a first in first our basis(add elements at the end and remove elements in the beginning)
Queue
a collections that we can add and remove elements from both ends
Deque
A collection of key-value pairs, where each key is unique and — to a single value.
Maps
Uses an array that can be sized dynamically
ArrayList
uses a series of nodes that point to the next node in the List
LinkedLists
stores elements using a hash table, which allows for efficient insertion, deletion, and lookup of elements. However, it does not guarantee any order of elements.
Hash set
stores elements in a sorted tree structure. The elements are automatically sorted in ascending order by default
Treeset
similar to HashSet, but it also maintains a linked list of elements in the order they were inserted
Linked Hashset
data structure that has no order to keys, no nulls
hash table