結果
問題 |
No.1543 [Cherry 2nd Tune A] これがプログラミングなのね
|
ユーザー |
|
提出日時 | 2021-06-12 07:40:58 |
言語 | C++17(clang) (17.0.6 + boost 1.87.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 324 bytes |
コンパイル時間 | 5,062 ms |
コンパイル使用メモリ | 162,048 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-15 21:29:31 |
合計ジャッジ時間 | 5,910 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | RE * 35 |
コンパイルメッセージ
main.cpp:8:18: warning: variable 'c' is uninitialized when used here [-Wuninitialized] 8 | work &= (c == '<'); | ^ main.cpp:5:21: note: initialize the variable 'c' to silence this warning 5 | int S, T; char c; | ^ | = '\0' main.cpp:7:8: warning: variable 'S' is uninitialized when used here [-Wuninitialized] 7 | if(S < T) { | ^ main.cpp:5:10: note: initialize the variable 'S' to silence this warning 5 | int S, T; char c; | ^ | = 0 main.cpp:7:12: warning: variable 'T' is uninitialized when used here [-Wuninitialized] 7 | if(S < T) { | ^ main.cpp:5:13: note: initialize the variable 'T' to silence this warning 5 | int S, T; char c; | ^ | = 0 3 warnings generated.
ソースコード
#include <bits/stdc++.h> using namespace std; int main() { int S, T; char c; bool work = true; if(S < T) { work &= (c == '<'); } else if(S > T) { work &= (c == '>'); } else { work &= (c == '='); } if(work) cout << "YES" << "\n"; else cout << "NO" << "\n"; }