2563 : 색종이

풀이

랭작조아

코드

#include <cstdio>
int n, r, x, y, i, j, a[101][101];
int main() {
    scanf("%d", &n);
    while (n--) {
        scanf("%d %d", &x, &y);
        for (i = x; i < x + 10; i++) for (j = y; j < y + 10; j++) r += !a[i][j]++;
    }
    printf("%d", r);
    return 0;
}

아무말

백준, 백준 온라인 저지, BOJ, Baekjoon Online Judge, C, C++, 씨, 씨쁠쁠, JAVA, algorithm, 자바, 알고리즘, 자료구조, 문제, 문제 풀이, 풀이

wookje.kwon's profile image

wookje.kwon

2018-04-04 20:16

Read more posts by this author