結果
問題 |
No.446 ゆきこーだーの雨と雪 (1)
|
ユーザー |
![]() |
提出日時 | 2016-11-18 22:55:37 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 504 bytes |
コンパイル時間 | 713 ms |
コンパイル使用メモリ | 55,380 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-26 07:37:10 |
合計ジャッジ時間 | 967 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 WA * 2 |
other | AC * 8 WA * 5 |
ソースコード
#include <iostream> #include <string> using namespace std; int main(void){ // Here your code ! string a,b; cin >> a >> b; try{ stoi(a,nullptr,10); stoi(b,nullptr,10); if( a[0] == '0' && a.size() != 1){ if( b[0] == '0' && b.size() != 1){ cout << "NG" << endl; }else{ cout << "OK" << endl; } }else{ cout << "OK" << endl; } }catch(const std::logic_error& e){ cout << "NG" << endl; } }