結果
問題 |
No.1314 N言っちゃダメゲーム (5)
|
ユーザー |
![]() |
提出日時 | 2023-05-11 11:38:40 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 724 bytes |
コンパイル時間 | 1,229 ms |
コンパイル使用メモリ | 124,864 KB |
最終ジャッジ日時 | 2025-02-12 21:19:39 |
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 17 WA * 11 |
ソースコード
#include <iostream> #include <fstream> #include <iomanip> #include <vector> #include <algorithm> #include <cmath> #include <unordered_map> #include <map> #include <queue> #include <string> #include <set> #include <list> #include <climits> #include <bitset> #include <numeric> #include <cassert> #include <regex> using std::cout; using std::cin; using std::string; using std::vector; int main() { int m, k; cin >> m >> k; int losing_games = (m-1)/(k+1); int wins = losing_games / 2; wins += (m - losing_games) / 2; if (wins > (m-1)/2) { cout << "Win"; } else if ((m-1) % 2 == 0 && wins == (m-1)/2) { cout << "Draw"; } else { cout << "Lose"; } }