private int[] getStepping(String content, int gramAmount) {
        if (content.length() <= order)
            return new int[0];
        if (gramAmount < 0)
            return getSequencial(content);
        int gramIndexLimit = content.length() - order + 1;
        // if gram count value is larger than the limit value, we get the max amount
        int gramCount = gramAmount;
        if (gramCount > gramIndexLimit)
            gramCount = gramIndexLimit;
        int s = gramIndexLimit / gramCount;
        int step = s < 3 ? 3 : s; // by default we make a stepping of 3
        int[] vals = new int[gramCount];

        int samplingPoint = 0;
        int startPoint = 0;

        for (int i = 0; i < vals.length; i++) {
            vals[i] = samplingPoint;
            samplingPoint += step;
            if (samplingPoint >= gramIndexLimit) {
                startPoint++;
                samplingPoint = startPoint;
            }
        }
        return vals;
    }