counting freq of each element
if ( mpp . containsKey ( digit_xor ( i ) ) ) mpp . put ( digit_xor ( i ) , mpp . get ( digit_xor ( i ) ) + 1 ) ; else mpp . put ( digit_xor ( i ) , 1 ) ; } int maxm = 0 ; for ( Map . Entry < Integer , Integer > x : mpp . entrySet ( ) ) {