ConcurrentLinkedDeque hashCode() method in Java with Example Last Updated : 27 Dec, 2018 Summarize Comments Improve Suggest changes Share Like Article Like Report The hashCode() method of ConcurrentLinkedDeque in Java is used to get the hashCode value for this instance of the ConcurrentLinkedDeque. It returns an integer value which is the hashCode value for this instance of the ConcurrentLinkedDeque. Syntax: public int hashCode() Parameters: This function has no parameters. Return Value: The method returns an integer value which is the hashCode value for this instance of the ConcurrentLinkedDeque. Below programs illustrate the ConcurrentLinkedDeque.hashCode() method: Program 1: Java // Java Program Demonstrate hashCode() // method of ConcurrentLinkedDeque import java.util.concurrent.ConcurrentLinkedDeque; import java.util.*; public class GFG { public static void main(String[] args) throws IllegalStateException { // create object of ConcurrentLinkedDeque ConcurrentLinkedDeque<Integer> CLD = new ConcurrentLinkedDeque<Integer>(); // Add numbers to end of ConcurrentLinkedDeque CLD.add(7855642); CLD.add(35658786); CLD.add(5278367); CLD.add(74381793); System.out.println("Linked Blocking Deque: " + CLD); // Get the hashCode value // using hashCode() value System.out.println("HashCode value: " + CLD.hashCode()); } } Output: Linked Blocking Deque: [7855642, 35658786, 5278367, 74381793] HashCode value: 2101973421 Program 2: Java // Java Program Demonstrate hashCode() // method of ConcurrentLinkedDeque // when the list contains characters import java.util.concurrent.ConcurrentLinkedDeque; import java.util.*; public class GFG { public static void main(String[] args) throws IllegalStateException { // create object of ConcurrentLinkedDeque ConcurrentLinkedDeque<String> CLD = new ConcurrentLinkedDeque<String>(); // Add numbers to end of ConcurrentLinkedDeque CLD.add("1"); CLD.add("2"); CLD.add("3"); CLD.add("4"); System.out.println("Linked Blocking Deque: " + CLD); // Get the hashCode value // using hashCode() value System.out.println("HashCode value: " + CLD.hashCode()); } } Output: Linked Blocking Deque: [1, 2, 3, 4] HashCode value: 2101973421 Comment More infoAdvertise with us Next Article ChronoPeriod hashCode() method in Java with Examples C code_r Follow Improve Article Tags : Java Java-Collections Java-Functions Java-ConcurrentLinkedDeque Practice Tags : JavaJava-Collections Similar Reads Duration hashCode() method in Java with Examples The hashCode() method of Duration Class in java.time package is used to get the hashCode value of this duration. Syntax: public int hashCode() Parameters: This method do not accepts any parameter. Return Value: This method returns an int value which is the hashCode value of this duration. Below exam 1 min read Charset hashCode() method in Java with Examples The hashCode() method is a built-in method of the java.nio.charset returns the computed hashcode of any given charset. Syntax: public final int hashCode() Parameters: The function does not accepts any parameter. Return Value: The function returns the computed hashcode for the charset. Below is the i 1 min read CompoundName hashCode() method in Java with Examples The hashCode() method of a javax.naming.CompoundName class is used to return the hash code of this compound name. The hash code of this compound name object is the sum of the hash codes of the "canonicalized" forms of individual components of this compound name. Syntax: public int hashCode() Paramet 2 min read ChronoPeriod hashCode() method in Java with Examples The hashCode() method of ChronoPeriod class in Java is used to get the generated hashCode for this period. Syntax: int hashCode() Parameters: This method does not accepts any parameter. Return Value: This method returns the hashCode generated for the given period. Below programs illustrate the hashC 2 min read ChronoZonedDateTime hashCode() method in Java with Examples The hashCode() method of a ChronoZonedDateTime interface is used to get the hashcode for this ChronoZonedDateTime. Hashcode is a unique code generated by the JVM at the time of object creation. It can be used to perform some operation on hashing related algorithm like a hashtable, hashmap etc. An ob 1 min read Double hashCode() method in Java with examples The hashCode() method of Double class is a built-in method use to return the hashcode value of this Double object. Syntax: DoubleObject.hashCode() Parameters: It takes no parameters. Return Type: It returns an int value. The value returned is (int)(v^(v>>>32)) where v is a long variable equ 1 min read Like