結果
問題 |
No.149 碁石の移動
|
ユーザー |
![]() |
提出日時 | 2022-08-23 10:15:11 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 277 bytes |
コンパイル時間 | 2,206 ms |
コンパイル使用メモリ | 192,672 KB |
最終ジャッジ日時 | 2025-01-31 03:02:55 |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 13 |
ソースコード
#include <bits/stdc++.h> using namespace std; #define int long long signed main(){ int a,b,c,d,e,f; cin>>a>>b>>c>>d>>e>>f; if(b >= e){ d += e; b -= e; } else{ e -= b; d += b; b = 0; a -= e; c += e; } cout<<a+min(c,f)<<endl; }