結果
| 問題 | No.539 インクリメント | 
| コンテスト | |
| ユーザー |  kyo1 | 
| 提出日時 | 2020-12-01 04:29:18 | 
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) | 
| 結果 | 
                                TLE
                                 
                             | 
| 実行時間 | - | 
| コード長 | 395 bytes | 
| コンパイル時間 | 92 ms | 
| コンパイル使用メモリ | 12,672 KB | 
| 実行使用メモリ | 18,080 KB | 
| 最終ジャッジ日時 | 2024-09-13 02:47:36 | 
| 合計ジャッジ時間 | 4,702 ms | 
| ジャッジサーバーID (参考情報) | judge2 / judge4 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 1 | 
| other | AC * 1 TLE * 1 -- * 1 | 
ソースコード
for _ in range(int(input())):
    S = input()[::-1]
    for i, s in enumerate(S):
        if s.isdigit():
            x = 0
            p = i
            while p < len(S) and S[p].isdigit():
                x += int(S[p]) * pow(10, p - i)
                p += 1
            x += 1
            S = S[:i] + ("0" * (p - i - len(str(x))) + str(x))[::-1] + S[p:]
            break
    print(S[::-1])
            
            
            
        