Function to find the pairs from the array such that one number is reverse of the other
public static int countReverse ( int arr [ ] , int n ) { HashMap < Integer , Integer > freq = new HashMap < > ( ) ;