結果
| 問題 | No.414 衝動 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2016-08-26 22:44:04 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0 + boost 1.89.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 384 bytes |
| 記録 | |
| コンパイル時間 | 1,301 ms |
| コンパイル使用メモリ | 157,940 KB |
| 実行使用メモリ | 6,820 KB |
| 最終ジャッジ日時 | 2024-11-08 14:40:37 |
| 合計ジャッジ時間 | 3,580 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 4 WA * 9 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int mod=1e9+7;
int main(){
ll m,a;
cin>>m;
a=m;
a%=mod;
if(a%2==0){
a/=2;
cout<<2<<" "<<a<<endl;
return 0;
} else {
for(int i=3; i*i<=m; i+=2){
if(a%i==0){
a/=i;
cout<<i<<" "<<a<<endl;
return 0;
}
}
}
cout<<1<<" "<<m<<endl;
return 0;
}