• + 0 comments
    for (int i = 0; i < n; i++) {
        int t = grades[i];
    
        if (t >= 38) {
            int nextMulof5 = ((t / 5) + 1) * 5;     //Calculation for next mul of 5
            if ((nextMulof5 - t) < 3) {
                grades[i] = nextMulof5;
            }
        }
    }