結果
| 問題 |
No.2870 Dice Making
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2024-09-06 21:27:00 |
| 言語 | C++23 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 617 bytes |
| コンパイル時間 | 6,031 ms |
| コンパイル使用メモリ | 337,208 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-09-06 21:27:08 |
| 合計ジャッジ時間 | 7,617 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 13 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
#include <atcoder/all>
using namespace atcoder;
#define ll long long
#define rep(i, n) for (ll i = 0; i < (ll)(n); i++)
using mint = modint998244353;
#define ull unsigned long long
random_device rnd;
mt19937 mt(rnd());
int RandInt(int a, int b) {
return a + mt() % (b - a + 1);
}
int main(){
int n,k;
cin>>n>>k;
for(int i=0;i<=n;i++){
if(i*k==n){
cerr<<":"<<i<<endl;
rep(j,i)cout<<1<<" ";
rep(j,n-i)cout<<2<<" ";
cout<<endl;
return 0;
}
}
cout<<-1<<endl;
return 0;
}