code: public void sort( int input[] , int startIndex ,int output[] , int startOutput , int length ) {
  		histogram.fill(0);
  
  		for( int i = 0; i < length; i++ ) {
  			histogram.data[input[i+startIndex]-minValue]++;
  		}
  
  		// over wrist the input data with sorted elements
  		int index = startOutput;
  		for( int i = 0; i < histogram.size; i++ ) {
  			int N = histogram.get(i);
  			int value = i+minValue;
  			for( int j = 0; j < N; j++ ) {
  				output[index++] = value;
  			}
  		}
  	}
docs: Sort routine which does not modify the input array.  Input and output arrays can be the same instance.
  
  @param input (Input) Data which is to be sorted. Not modified.
  @param startIndex First element in input list
  @param output (Output) Sorted data. Modified.
  @param length Number of elements