Submitted by heartin on Fri, 10/09/2015 - 19:58
We can use logical operators AND (&&) and OR (||) in the logical expressions. The AND operator returns true if both conditions are true while OR returns true if only one of the conditions is true.
Short circuit operators
-
The logical operators && and || are called short circuit operators.
-
Short circuiting is the process of stop evaluating remainder of a logical expression once the result becomes obvious.
Submitted by heartin on Thu, 10/08/2015 - 11:05
HashMap is a Hash table based implementation of the Map interface. For more details on hashing, you can refer to http://javajee.com/hashing-basics.
Important properties of HashMap
-
Provides all of the optional map operations
-
Permits null values and the null key.
-
Roughly equivalent to Hashtable, except that it is unsynchronized and permits nulls.
Submitted by heartin on Thu, 10/08/2015 - 09:03
Map is an object that maps keys to values.
Important properties of a Map
-
A map cannot contain duplicate keys
-
Each key can map to at most one value.
-
Map interface takes the place of the abstract Dictionary class.
-
The order of a map is the order in which the iterators on the map's collection views return their elements.
Submitted by heartin on Wed, 10/07/2015 - 22:38
Important properties of LinkedList
-
Doubly-linked list implementation
-
Implements all optional list operations
-
permits all elements (including null)
-
is not synchronized
Submitted by heartin on Wed, 10/07/2015 - 21:21
List is an ordered collection.
Important points about List interface
-
also known as a sequence.
-
typically allow duplicate
-
Places additional stipulations on the contracts of the iterator, add, remove, equals, and hashCode methods.
Pages