結果
問題 |
No.431 死亡フラグ
|
ユーザー |
|
提出日時 | 2016-10-15 11:12:46 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 430 bytes |
コンパイル時間 | 671 ms |
コンパイル使用メモリ | 58,204 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-22 11:26:17 |
合計ジャッジ時間 | 1,109 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 16 |
ソースコード
#include <iostream> #include <cstdint> #include <vector> using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(0); int sibou = 0; vector<int> v(4); for (auto& i : v) { cin >> i; if (i == 1) sibou++; } if (v.at(3) == 1) { cout << "SURVIVED" << endl; } else { if (sibou < 2) { cout << "SURVIVED" << endl; } else { cout << "DEAD" << endl; } } return 0; }