結果
| 問題 | No.3159 Just Answer 10 Integers! | 
| コンテスト | |
| ユーザー |  ゼリトキ | 
| 提出日時 | 2025-05-23 20:20:07 | 
| 言語 | C++23 (gcc 13.3.0 + boost 1.87.0) | 
| 結果 | 
                                WA
                                 
                             | 
| 実行時間 | - | 
| コード長 | 855 bytes | 
| コンパイル時間 | 3,107 ms | 
| コンパイル使用メモリ | 285,976 KB | 
| 実行使用メモリ | 7,844 KB | 
| 最終ジャッジ日時 | 2025-05-23 20:20:13 | 
| 合計ジャッジ時間 | 4,623 ms | 
| ジャッジサーバーID (参考情報) | judge3 / judge5 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 1 | 
| other | AC * 2 WA * 7 | 
ソースコード
#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (ll i = 0; i < (ll)(n); i++)
#define ll long long
const long long mod=998244353;
const long long hmod=46216567629137;
int main(){
    cin.tie(0)->sync_with_stdio(0);
    cout.tie(0);
    int N;
    cin>>N;
    int n=N;
    if(N==2){
        cout<<"2 3\n";
        return 0;
    }
    if(N==3){
        N*=4;
    }
    if(N==4){
        N*=3;
    }
    if(N==5){
        N*=6;
    }
    if(N==6){
        N*=7;
    }
    if(N==7){
        N*=12;
    }
    if(N==8){
        N*=15;
    }
    if(N==9){
        N*=10;
    }
    if(N==10){
        N*=21;
    }
    vector<int>dat;
    for(int i=1;i*i<=N;i++){
        if(N%i==0){
            dat.push_back(i);
            dat.push_back(N/i);
        }
    }
    sort(dat.rbegin(),dat.rend());
    rep(i,n){
        cout<<dat[i]<<" ";
    }
}
            
            
            
        