Java Arrays.deepHashCode(Object [] a)

Syntax

Arrays.deepHashCode(Object [] a) has the following syntax.

public static int deepHashCode(Object [] a)

Example

In the following code shows how to use Arrays.deepHashCode(Object [] a) method.


//w  w w . j a va 2  s  .  c om


import java.util.Arrays;

public class Main {

  public static void main(String[] args) {

   Object[] ob = { "java2s","java2s.com" };
    
   // deephashcode for object ob
   int retval=Arrays.deepHashCode(ob);
    
   System.out.println("The Hash Code of ob is:" + retval);
  }
}

The code above generates the following result.