U E D R , A S I H C RSS

ACM_ICPC/Problems/6465

No difference found




황현

#include <stdio.h>


int main() {
        int c, z = 0, y, i, l, u, s, d;
        scanf("%d", &c);
        for(; z < c; ++z) {
                scanf("%d", &i);
                s = 0;
                scanf("%d", &l);
                for(y = 0; y < 14; ++y) {
                        scanf("%d", &u);
                        d = u - l;
                        l = u;
                        if(d == 1)
                                ++s;
                }
                printf("%d %d\n", i, s);
        }

        return 0;
}
Valid XHTML 1.0! Valid CSS! powered by MoniWiki
last modified 2021-02-07 05:22:20
Processing time 0.0338 sec