# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
4952 |
2014-01-23T13:24:19 Z |
hana5505 |
고기잡이 (KOI13_fish) |
C++ |
|
124 ms |
1088 KB |
#include<stdio.h>
struct pp{int x,y;}fish[101];int m;int fish_count(int x,int y,int p,int q){int i,cnt=0;for(i=1;i<=m;i++)if(x<=fish[i].x && fish[i].x<=p && y<=fish[i].y && fish[i].y<=q)cnt++;return cnt;}int main(){int n,l,i,j,k,t,ans=0;scanf("%d %d %d",&n,&l,&m);for(i=1;i<=m;i++)scanf("%d %d",&fish[i].x,&fish[i].y);for(i=1;i<=m;i++){for(j=1;j<=m;j++){for(k=1;k<l/2;k++){t=fish_count(fish[i].x,fish[j].y,fish[i].x+k,fish[j].y+(l/2-k));if(t>ans) ans=t;}}}printf("%d",ans);}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
1088 KB |
Output is correct |
2 |
Correct |
0 ms |
1088 KB |
Output is correct |
3 |
Correct |
0 ms |
1088 KB |
Output is correct |
4 |
Correct |
0 ms |
1088 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
1088 KB |
Output is correct |
2 |
Correct |
0 ms |
1088 KB |
Output is correct |
3 |
Correct |
0 ms |
1088 KB |
Output is correct |
4 |
Correct |
0 ms |
1088 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
8 ms |
1088 KB |
Output is correct |
2 |
Correct |
8 ms |
1088 KB |
Output is correct |
3 |
Correct |
20 ms |
1088 KB |
Output is correct |
4 |
Correct |
44 ms |
1088 KB |
Output is correct |
5 |
Correct |
0 ms |
1088 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
1088 KB |
Output is correct |
2 |
Correct |
68 ms |
1088 KB |
Output is correct |
3 |
Correct |
68 ms |
1088 KB |
Output is correct |
4 |
Correct |
68 ms |
1088 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
120 ms |
1088 KB |
Output is correct |
2 |
Correct |
64 ms |
1088 KB |
Output is correct |
3 |
Correct |
88 ms |
1088 KB |
Output is correct |
4 |
Correct |
124 ms |
1088 KB |
Output is correct |