Submission #9486

# Submission time Handle Problem Language Result Execution time Memory
9486 2014-09-28T06:47:26 Z YesUjam N-orthotope (kriii2_N) C++
0 / 4
0 ms 1088 KB
#include <cstdio>

int main() {
	int n;
	int a[11][2], b[11][2];
	scanf("%d", &n);
	for(int i=0; i<n; i++) {
		scanf("%d %d", &a[i][0], &a[i][1]);
	}
	for(int i=0; i<n; i++) {
		scanf("%d %d", &b[i][0], &b[i][1]);
	}
	int ans = n;
	for(int i=0; i<n; i++) {
		if(a[i][1] == b[i][0] || a[i][0] == b[i][1]) ans--;
		else if(a[i][0] > b[i][1] || a[i][1] < b[i][0]) {
			printf("0\n");
			break;
		}
	}
	printf("%d\n", ans);
}
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 1088 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Halted 0 ms 0 KB -