Submission #00003


ソースコード

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#include <bits/stdc++.h>
using namespace std;
int main(){
int a,b,c;
cin>>a>>b>>c;
long long sum=0;
int day=1;
while(true){
sum+=b;
if(sum>=a){
break;
}
sum-=c;
day++;
}
cout<<day<<"\n";
return(0);
}

ステータス

項目 データ
問題 0004 - パンケーキの水やり
ユーザー名 ei2122
投稿日時 2022-11-14 09:24:06
言語 C++17
状態 Accepted
得点 1
ソースコード長 302 Byte
最大実行時間 30 ms
最大メモリ使用量 652 KB

セット

セット 得点 Cases
1 ALL 1 / 1 *

テストケース

ファイル名 状態 実行時間 メモリ使用量 #
input01.txt AC 30 ms 604 KB
1
input02.txt AC 22 ms 580 KB
1
input03.txt AC 26 ms 552 KB
1
input04.txt AC 23 ms 652 KB
1
input05.txt AC 19 ms 624 KB
1