結果

問題 No.18 うーさー暗号
ユーザー ABKZABKZ
提出日時 2021-06-12 16:06:19
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 109 ms / 5,000 ms
コード長 192 bytes
コンパイル時間 1,097 ms
コンパイル使用メモリ 87,084 KB
実行使用メモリ 72,584 KB
最終ジャッジ日時 2023-08-22 13:59:14
合計ジャッジ時間 2,625 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 106 ms
72,272 KB
testcase_01 AC 107 ms
72,144 KB
testcase_02 AC 109 ms
72,224 KB
testcase_03 AC 107 ms
72,472 KB
testcase_04 AC 107 ms
72,584 KB
testcase_05 AC 106 ms
72,144 KB
testcase_06 AC 106 ms
72,452 KB
testcase_07 AC 105 ms
72,272 KB
testcase_08 AC 106 ms
72,224 KB
testcase_09 AC 106 ms
72,496 KB
testcase_10 AC 108 ms
72,452 KB
testcase_11 AC 105 ms
72,436 KB
testcase_12 AC 104 ms
72,372 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from functools import reduce

S = input()
ans = reduce(lambda a, b: a + b,
             [chr(ord("Z") - (ord("Z") - ord(c) + i) % 26)
                 for i, c in enumerate(S, 1)])

print(ans)
0