class ObjectHistogram implements Histogram<T, ObjectHistogram<T>>, DistributionComputer {

    @Override public TreeMap<Integer, Double> computeDistributionFunction() {
        TreeMap<Integer, Double> res = new TreeMap<>();

        double accum = 0.0;
        for (Integer bucket : hist.keySet()) {
            accum += hist.get(bucket);
            res.put(bucket, accum);
        }

        return res;
    }

}