結果
問題 | No.2246 1333-like Number |
ユーザー |
|
提出日時 | 2023-03-24 20:57:13 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 3 ms / 2,000 ms |
コード長 | 492 bytes |
コンパイル時間 | 3,389 ms |
コンパイル使用メモリ | 251,144 KB |
最終ジャッジ日時 | 2025-02-11 16:53:23 |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 24 |
ソースコード
#include <bits/stdc++.h> #include <atcoder/all> using namespace std; using namespace atcoder; using ll = long long; int main(void) { int n; cin >> n; n--; vector<int> koho; for(int i = 1; i <= 9; i++) { for(int j = i + 1; j <= 9; j++) { koho.push_back(10 * i + j); } } int m = koho.size(); int x = n / m; int y = n % m; cout << koho[y]; for(int i = 0; i < x; i++) cout << koho[y] % 10; cout << endl; return 0; }