結果

問題 No.2034 Anti Lexicography
ユーザー zozo
提出日時 2022-09-15 10:21:39
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
TLE  
実行時間 -
コード長 375 bytes
コンパイル時間 152 ms
コンパイル使用メモリ 10,812 KB
実行使用メモリ 14,408 KB
最終ジャッジ日時 2023-08-22 06:47:40
合計ジャッジ時間 5,088 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 27 ms
13,604 KB
testcase_01 AC 27 ms
9,112 KB
testcase_02 AC 27 ms
9,208 KB
testcase_03 AC 26 ms
9,152 KB
testcase_04 AC 26 ms
9,268 KB
testcase_05 TLE -
testcase_06 -- -
testcase_07 -- -
testcase_08 -- -
testcase_09 -- -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
testcase_14 -- -
testcase_15 -- -
testcase_16 -- -
testcase_17 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

c=int(input())
st=str(input())
import string
asc=string.ascii_letters
sum=0
result=""
for i in range(c):
    sum+=(int(ord(st[i]))-96)*(26**(c-i-1))
re=(26**c-sum)
for i in range(c):
    if i==c-1:
        result+=chr(int((re%(26**(c-i))-re%(26**(c-i-1)))/(26**(c-i-1)))+97)
    else:
        result+=chr(int((re%(26**(c-i))-re%(26**(c-i-1)))/(26**(c-i-1)))+98)
print(result)
0