結果
| 問題 |
No.2868 Another String of yuusaan
|
| コンテスト | |
| ユーザー |
lam6er
|
| 提出日時 | 2025-03-20 20:51:44 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 488 bytes |
| コンパイル時間 | 172 ms |
| コンパイル使用メモリ | 82,684 KB |
| 実行使用メモリ | 206,568 KB |
| 最終ジャッジ日時 | 2025-03-20 20:51:49 |
| 合計ジャッジ時間 | 3,705 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | TLE * 1 -- * 17 |
ソースコード
s = 'yuusaan'
n, k = map(int, input().split())
while n > 1:
current_len = 0
for c in s:
if c in ('u', 'a'):
block_len = 7 ** (n - 1)
else:
block_len = 1
if current_len + block_len >= k:
if c not in ('u', 'a'):
print(c)
exit()
else:
k -= current_len
n -= 1
break
else:
current_len += block_len
print(s[k-1])
lam6er