結果

問題 No.1528 Not 1
ユーザー inakuki
提出日時 2021-06-05 07:38:08
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 435 bytes
コンパイル時間 1,453 ms
コンパイル使用メモリ 165,944 KB
実行使用メモリ 6,820 KB
最終ジャッジ日時 2024-11-21 00:33:07
合計ジャッジ時間 3,945 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample WA * 1
other AC * 14 WA * 5
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<bits/stdc++.h>
using namespace std;
int main(){
    int n;cin>>n;
    if(n==3||n==5){
        cout << -1;
        return 0;
    }
    if(n==1){
        cout << 1;
        return 0;
    }
    if(n%2==0){
        for(int i=0;i<n/2;i++)cout << (i+1)*2 << " ";
        return 0;
    }
    cout << 3 << " " << 6 << " ";
    for(int i=0;i<n/2;i++){
        if(i==2)continue;
        cout << (i+1)*2 << " ";
        return 0;
    }
}
0