結果
問題 | No.722 100×100=1000 |
ユーザー |
![]() |
提出日時 | 2018-10-10 16:59:56 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 438 bytes |
コンパイル時間 | 1,500 ms |
コンパイル使用メモリ | 165,752 KB |
実行使用メモリ | 13,636 KB |
最終ジャッジ日時 | 2024-10-12 11:14:01 |
合計ジャッジ時間 | 5,146 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 7 WA * 2 TLE * 1 -- * 17 |
ソースコード
#include <bits/stdc++.h> using namespace std; typedef long long ll; bool check(ll x){ while(x % 10 == 0) x /= 10; return x >= -9 and x <= 9; } int main(){ cin.tie(0); ios::sync_with_stdio(false); ll a, b, ans; cin >> a >> b; if(check(a) and check(b)){ ans = a * b / 10; cout << ans << endl; return 0; } ans = a * b; if(ans >= -99999999 and ans <= 99999999) cout << ans << endl; else cout << 'E' << endl; return 0; }