
double decisions[{0}];
for (i = 0, d = 0, l = {1}; i < l; i++) {{
    for (j = i + 1; j < l; j++) {{
        double tmp = 0.;
        for (k = starts[j]; k < ends[j]; k++) {{
            tmp += kernels[k] * coeffs[i][k];
        }}
        for (k = starts[i]; k < ends[i]; k++) {{
            tmp += kernels[k] * coeffs[j - 1][k];
        }}
        decisions[d] = tmp + inters[d];
        d = d + 1;
    }}
}}
