結果
問題 | No.63 ポッキーゲーム |
ユーザー |
![]() |
提出日時 | 2024-10-30 21:05:46 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 192 ms / 5,000 ms |
コード長 | 334 bytes |
コンパイル時間 | 1,939 ms |
コンパイル使用メモリ | 167,276 KB |
実行使用メモリ | 6,824 KB |
最終ジャッジ日時 | 2024-10-30 21:05:50 |
合計ジャッジ時間 | 3,730 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 22 |
ソースコード
#include<bits/stdc++.h>using namespace std;#define rep(i,n) for(int i = 0; i < int(n); i++)using ll = long long;int main(){cin.tie(nullptr);ios_base::sync_with_stdio(false);int l,k;cin >> l >> k;int ans = 0;int now = l;while(now - 2 * k > 0){now -= 2*k;ans += k;}cout << ans << endl;return 0;}