結果
| 問題 |
No.1628 Sorting Integers (MAX of M)
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-07-30 22:55:38 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 446 bytes |
| コンパイル時間 | 963 ms |
| コンパイル使用メモリ | 93,632 KB |
| 最終ジャッジ日時 | 2025-01-23 12:35:59 |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 6 |
ソースコード
#include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <utility>
#include <map>
#include <cmath>
using namespace std;
typedef long long ll;
#define rep(i, n) for (int i=0;i < (int)(n);i++)
int main(){
int n;
cin >> n;
string ans = "";
rep(i,9){
int x;
cin >> x;
rep(j,x) ans += ('0'+(i+1));
}
reverse(ans.begin(),ans.end());
cout << ans << endl;
return 0;
}