1780
-
백준 1780번 종이의 개수PS 2021. 4. 8. 02:09
www.acmicpc.net/problem/1780 #include #include #include using namespace std; #define MAX 2188 int n; int oneCnt, zeroCnt, moneCnt; int map[MAX][MAX]; void counting(int num) { if (num == -1) { moneCnt++; } else if (num == 0) { zeroCnt++; } else { oneCnt++; } } void solve(int y, int x, int size) { if (size == 1) { counting(map[y][x]); return; } bool br = false; for (int i = y; i < y + size; i++) {..