結果
| 問題 | No.3629 Maximize Subsequense Mex |
| コンテスト | |
| ユーザー |
detteiuu
|
| 提出日時 | 2026-08-14 22:50:58 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 65 ms / 2,000 ms |
| + 483µs | |
| コード長 | 380 bytes |
| 記録 | |
| コンパイル時間 | 252 ms |
| コンパイル使用メモリ | 95,852 KB |
| 実行使用メモリ | 87,076 KB |
| 最終ジャッジ日時 | 2026-08-14 22:51:29 |
| 合計ジャッジ時間 | 7,886 ms |
|
ジャッジサーバーID (参考情報) |
judge2_1 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 27 |
ソースコード
from sys import stdin
input = stdin.readline
for _ in range(int(input())):
N = int(input())
if N <= 9:
print("0123456789"[:N][::-1])
continue
ans = []
while N:
if 10 <= N:
ans.append("9876543210")
N -= 10
else:
ans.append("123456789"[:N][::-1])
N = 0
print("".join(ans[::-1]))
detteiuu