結果

問題 No.722 100×100=1000
ユーザー pyraninepyranine
提出日時 2020-12-19 16:55:13
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 1,165 bytes
コンパイル時間 1,539 ms
コンパイル使用メモリ 168,612 KB
実行使用メモリ 4,348 KB
最終ジャッジ日時 2023-10-21 09:22:14
合計ジャッジ時間 3,081 ms
ジャッジサーバーID
(参考情報)
judge13 / judge9
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 AC 2 ms
4,348 KB
testcase_03 WA -
testcase_04 WA -
testcase_05 AC 2 ms
4,348 KB
testcase_06 AC 1 ms
4,348 KB
testcase_07 WA -
testcase_08 AC 1 ms
4,348 KB
testcase_09 AC 1 ms
4,348 KB
testcase_10 AC 1 ms
4,348 KB
testcase_11 AC 2 ms
4,348 KB
testcase_12 AC 1 ms
4,348 KB
testcase_13 AC 2 ms
4,348 KB
testcase_14 AC 2 ms
4,348 KB
testcase_15 WA -
testcase_16 AC 1 ms
4,348 KB
testcase_17 AC 1 ms
4,348 KB
testcase_18 AC 2 ms
4,348 KB
testcase_19 WA -
testcase_20 WA -
testcase_21 AC 2 ms
4,348 KB
testcase_22 AC 2 ms
4,348 KB
testcase_23 AC 2 ms
4,348 KB
testcase_24 AC 2 ms
4,348 KB
testcase_25 AC 2 ms
4,348 KB
testcase_26 AC 1 ms
4,348 KB
testcase_27 AC 1 ms
4,348 KB
testcase_28 WA -
testcase_29 WA -
testcase_30 AC 1 ms
4,348 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;

using i32 = int32_t;using i64 = int64_t;using u32 = uint32_t;using u64 = uint64_t;using f32 = float;using f64 = double;using f80 = long double;
using i128 = __int128_t;using u128 = __uint128_t;
using vi32 = vector<i32>;using vi64 = vector<i64>;using vu32 = vector<u32>;using vu64 = vector<u64>;
using vvi32 = vector<vector<int32_t>>;using vvi64 = vector<vector<int64_t>>;using vvu32 = vector<vector<uint32_t>>;using vvu64 = vector<vector<uint64_t>>;
using pi32 = pair<i32,i32>;using pi64 = pair<i64,i64>;using Pu32 = pair<u32,u32>;using Pu64 = pair<u64,u64>;
using vpi32 = vector<pi32>;using vpi64 = vector<pi64>;using vpu32 = vector<Pu32>;using vpu64 = vector<Pu64>;

int main() {
  i64 a, b, c, d, e, f;
  cin >> a >> b;
  if (a == 0 || b == 0) {
    cout << 0 << endl;
    return 0;
  }
  c = abs(a);
  d = abs(b);
  e = 0;
  f = 0;
  while (c % 10LL != 0) {
    c /= 10;
    e++;
  }
  while (d % 10LL != 0) {
    d /= 10;
    f++;
  }
  if (c > 9 || d > 9 || e < 2 || f < 2) {
    cout << (abs(a * b) < 100000000LL ? to_string(a * b) : "E") << endl;
    return 0;
  }
  cout << a * b / 10LL << endl;
  return 0;
}
0