結果
問題 | No.537 ユーザーID |
ユーザー |
|
提出日時 | 2018-01-13 12:11:56 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 15 ms / 2,000 ms |
コード長 | 367 bytes |
コンパイル時間 | 847 ms |
コンパイル使用メモリ | 73,728 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-23 23:46:13 |
合計ジャッジ時間 | 2,145 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 32 |
ソースコード
#include <iostream> #include <string> #include <set> using namespace std; int main() { long long n; cin >> n; set<long long> nums; for (long long i = 1; i * i <= n; i++) { if(n % i == 0) { string s = to_string(i); string t = to_string(n / i); nums.insert(stol(s + t)); nums.insert(stol(t + s)); } } cout << nums.size() << endl; return 0; }