static boolean shiftRight(int[] result,int resultLen,int[] source,int intCount,int count){
  int i;
  boolean allZero=true;
  for (i=0; i < intCount; i++)   allZero&=source[i] == 0;
  if (count == 0) {
    System.arraycopy(source,intCount,result,0,resultLen);
    i=resultLen;
  }
 else {
    int leftShiftCount=32 - count;
    allZero&=(source[i] << leftShiftCount) == 0;
    for (i=0; i < resultLen - 1; i++) {
      result[i]=(source[i + intCount] >>> count) | (source[i + intCount + 1] << leftShiftCount);
    }
    result[i]=(source[i + intCount] >>> count);
    i++;
  }
  return allZero;
}

static boolean shiftRight ( int [ ] result , int resultLen , int [ ] source , int intCount , int count ) { int i ; boolean allZero = true ; for ( i = 0 ; i < intCount ; i ++ ) allZero &= source [ i ] == 0 ; if ( count == 0 ) { System . arraycopy ( source , intCount , result , 0 , resultLen ) ; i = resultLen ; } else { int leftShiftCount = 32 - count ; allZero &= ( source [ i ] << leftShiftCount ) == 0 ; for ( i = 0 ; i < resultLen - 1 ; i ++ ) { result [ i ] = ( source [ i + intCount ] > > > count ) | ( source [ i + intCount + 1 ] << leftShiftCount ) ; } result [ i ] = ( source [ i + intCount ] > > > count ) ; i ++ ; } return allZero ; }
shifts right an array of integers . total shift distance in bits is intcount * 32 + count .
