code: public static int count(int[] histogram, int N) {
  		int counts = 0;
  		for(int i=0;i<N;i++) {
  			counts += histogram[i];
  		}
  		return counts;
  	}
docs: Counts sum of all the bins inside the histogram
  
  @param histogram Histogram with N bins
  @param N number of bins in the histogram.
  @return Sum of all values in the histogram array.