結果
| 問題 |
No.722 100×100=1000
|
| コンテスト | |
| ユーザー |
nxteru
|
| 提出日時 | 2018-08-03 22:36:42 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 640 bytes |
| コンパイル時間 | 868 ms |
| コンパイル使用メモリ | 82,232 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-12-29 19:20:33 |
| 合計ジャッジ時間 | 1,946 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 27 |
ソースコード
#include <iostream>
#include <algorithm>
#include <vector>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <cstdio>
#include <cstring>
#include <math.h>
using namespace std;
typedef long long ll;
typedef double D;
typedef pair<int,int> P;
#define M 1000000007
#define F first
#define S second
#define PB push_back
ll a,b;
int main(void){
cin>>a>>b;
ll c=a,d=b;
while(c!=0&&c%10==0)c/=10;
while(d!=0&&d%10==0)d/=10;
if(0<abs(c)&&abs(c)<10&&0<abs(d)&&abs(d)<10&&abs(a)>99&&abs(b)>99){
cout<<a*b/10<<endl;
}else if(-99999999<=a*b&&a*b<=99999999)cout<<a*b<<endl;
else cout<<"E\n";
}
nxteru