| # | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
|---|---|---|---|---|---|---|---|
| 40885 | cdjs1432 | 쌍둥이 독수리 (GA7_twineagles) | C11 | 1083 ms | 496 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <stdio.h>
#include <stdlib.h>
int main()
{
int LH,S,D;
int tempS,tempD;
int L,B;
int atk=2;
long long day1=0,day2=0;
scanf("%d %d %d %d %d",&LH,&S,&D,&L,&B);
tempS=S,tempD=D;
while (D>0||S>0)
{
day1++;
atk=2;
if (S>2*LH)
S-=2*LH;
else if (S>0)
S-=LH,D-=LH;
else
D-=LH*2;
if (S>0)
S+=L;
if (D>0)
D+=B;
}
S=tempS,D=tempD;
while (D>0||S>0)
{
day2++;
atk=2;
if (D>2*LH)
D-=2*LH;
else if (D>0)
D-=LH,S-=LH;
else
S-=LH*2;
if (S>0)
S+=L;
if (D>0)
D+=B;
}
printf("%lld",(day2<day1)?day2:day1);
}
컴파일 시 표준 에러 (stderr) 메시지
| # | 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... | ||||
