結果
問題 |
No.1317 月曜日の朝、WAを出した
|
ユーザー |
|
提出日時 | 2021-01-22 18:44:38 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 894 bytes |
コンパイル時間 | 832 ms |
コンパイル使用メモリ | 100,408 KB |
最終ジャッジ日時 | 2025-01-18 03:28:21 |
ジャッジサーバーID (参考情報) |
judge1 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 1 WA * 3 |
コンパイルメッセージ
main.cpp: In function ‘void solve()’: main.cpp:21:29: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 21 | for (auto &&i : a) scanf("%d", &i); | ~~~~~^~~~~~~~~~ main.cpp:22:29: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 22 | for (auto &&i : b) scanf("%d", &i); | ~~~~~^~~~~~~~~~
ソースコード
#include <iostream> #include <algorithm> #include <map> #include <set> #include <queue> #include <stack> #include <numeric> #include <bitset> #include <cmath> static const int MOD = 1000000007; using ll = long long; using u32 = unsigned; using u64 = unsigned long long; using namespace std; template<class T> constexpr T INF = ::numeric_limits<T>::max() / 32 * 15 + 208; void solve(){ vector<int> a(6), b(6); for (auto &&i : a) scanf("%d", &i); for (auto &&i : b) scanf("%d", &i); string s; cin >> s; int cur = 1; if(s == "TLE") cur = 2; if(s == "MLE") cur = 3; if(s == "OLE") cur = 4; if(s == "RE") cur = 5; for (int i = 1; i <= 5; ++i) { if(cur != i && b[i] != 0){ puts("No"); return; } } puts("Yes"); } int main() { int t; cin >> t; while(t--){ solve(); } return 0; }