private static long lowMask ( char first , char last ) { long m = 0 ; int f = Math . max ( Math . min ( first , 63 ) , 0 ) ; int l = Math . max ( Math . min ( last , 63 ) , 0 ) ; for ( int i = f ; i <= l ; i ++ ) m |= 1L << i ; return m ; }
between first and last inclusive