結果
問題 |
No.312 置換処理
|
ユーザー |
![]() |
提出日時 | 2016-08-19 01:12:10 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 369 bytes |
コンパイル時間 | 673 ms |
コンパイル使用メモリ | 76,308 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-07 19:36:35 |
合計ジャッジ時間 | 2,359 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 35 WA * 10 |
ソースコード
#include <iostream> #include <fstream> #include <vector> #include <cstring> #include <string> #include <algorithm> #include <iomanip> using namespace std; typedef long long ll; int f(ll n) { for(ll i = 3; i * i <= n; i++) { if(n % i == 0) return i; } return n; } int main() { cin.tie(0); ios::sync_with_stdio(false); ll N; cin >> N; cout << f(N) << endl; }