#include <stdio.h>
int main(){
int n,i,j;
scanf("%d",&n);
int a[n],b[n],c[n];
for (i=0; i<n; i++) {
scanf("%d %d",&a[i],&b[i]);
c[i]=1;
}
for (i=0; i<n; i++) {
for (j=0; j<n; j++) c[i]+=(a[i]<a[j])&&(b[i]<b[j]);
}
for (i=0; i<n; i++) {
printf("%d ",c[i]);
}
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
1204 KB |
Output is correct |
2 |
Correct |
0 ms |
1204 KB |
Output is correct |
3 |
Correct |
0 ms |
1204 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
1204 KB |
Output is correct |
2 |
Correct |
0 ms |
1204 KB |
Output is correct |
3 |
Correct |
0 ms |
1204 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
1204 KB |
Output is correct |
2 |
Correct |
0 ms |
1204 KB |
Output is correct |
3 |
Correct |
0 ms |
1204 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
1204 KB |
Output is correct |
2 |
Correct |
0 ms |
1204 KB |
Output is correct |
3 |
Correct |
0 ms |
1204 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
1204 KB |
Output is correct |
2 |
Correct |
0 ms |
1204 KB |
Output is correct |
3 |
Correct |
0 ms |
1204 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
1204 KB |
Output is correct |
2 |
Correct |
0 ms |
1204 KB |
Output is correct |
3 |
Correct |
0 ms |
1204 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
1204 KB |
Output is correct |
2 |
Correct |
0 ms |
1204 KB |
Output is correct |