結果
| 問題 |
No.1383 Numbers of Product
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-12-09 08:10:24 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 471 bytes |
| コンパイル時間 | 1,521 ms |
| コンパイル使用メモリ | 166,320 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-07-16 18:30:18 |
| 合計ジャッジ時間 | 7,557 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 5 RE * 46 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
long long n, k, m;
int main(){
cin >> n >> k >> m;
long long a = 1;
long long Key[n + 1] = {0};
while (a*(a + k) <= n){
long long cur = a*(a + k);
for (int i = 1; cur <= n; cur *= (a + k*i)){
++Key[cur];
++i;
}
++a;
}
long long res = 0;
for (long long i = 1; i <= n; ++i){
if (Key[i] == m) ++res;
}
cout << res << endl;
}