This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <stdio.h>
int a[500],b[500],ra[500];
int main()
{
int n,i,j,cnt=0;
scanf("%d\n",&n);
for(i=0;i<n;i++)
{
scanf("%d %d\n",&a[i],&b[i]);
ra[i]=1;
}
for(i=0;i<n;i++)
{
cnt=0;
for(j=0;j<n;j++)
{
if(i==j) continue;
if(a[i]<a[j] && b[i]<b[j]) cnt++;
}
ra[i]+=cnt;
printf("%d\n",ra[i]);
}
return 0;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |