結果
| 問題 |
No.537 ユーザーID
|
| コンテスト | |
| ユーザー |
hotpepsi
|
| 提出日時 | 2017-08-31 23:07:46 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 16 ms / 2,000 ms |
| コード長 | 414 bytes |
| コンパイル時間 | 720 ms |
| コンパイル使用メモリ | 70,448 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-11-06 16:46:36 |
| 合計ジャッジ時間 | 1,799 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 32 |
ソースコード
#include <iostream>
#include <sstream>
#include <set>
#include <cmath>
using namespace std;
int main(int argc, char *argv[])
{
long long n, r, i, d;
set<string> m;
cin >> n;
r = sqrt(n);
for (i = 1; i <= r; ++i) {
d = n / i;
if (i * d == n) {
char w[64];
sprintf(w, "%lld%lld", i, d);
m.insert(w);
sprintf(w, "%lld%lld", d, i);
m.insert(w);
}
}
cout << m.size() << endl;
return 0;
}
hotpepsi