結果

問題 No.2034 Anti Lexicography
ユーザー asumo0729asumo0729
提出日時 2022-08-12 21:34:25
言語 PyPy3
(7.3.13)
結果
AC  
実行時間 107 ms / 2,000 ms
コード長 981 bytes
コンパイル時間 1,166 ms
コンパイル使用メモリ 81,516 KB
実行使用メモリ 89,672 KB
最終ジャッジ日時 2023-10-24 08:35:54
合計ジャッジ時間 2,867 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 51 ms
60,988 KB
testcase_01 AC 50 ms
60,988 KB
testcase_02 AC 50 ms
60,988 KB
testcase_03 AC 51 ms
60,988 KB
testcase_04 AC 51 ms
60,988 KB
testcase_05 AC 107 ms
89,664 KB
testcase_06 AC 103 ms
89,664 KB
testcase_07 AC 101 ms
89,656 KB
testcase_08 AC 103 ms
89,672 KB
testcase_09 AC 103 ms
89,656 KB
testcase_10 AC 103 ms
89,664 KB
testcase_11 AC 104 ms
89,668 KB
testcase_12 AC 105 ms
89,664 KB
testcase_13 AC 55 ms
64,204 KB
testcase_14 AC 55 ms
64,204 KB
testcase_15 AC 56 ms
64,208 KB
testcase_16 AC 56 ms
64,208 KB
testcase_17 AC 56 ms
66,268 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
from operator import itemgetter
from collections import defaultdict, deque
import heapq
from heapq import heapify, heappop, _heapify_max, heappush
from bisect import bisect_left, bisect_right
import math
import itertools
import copy

stdin=sys.stdin
#sys.setrecursionlimit(10 ** 7)
## import pypyjit
## pypyjit.set_param('max_unroll_recursion=-1')

ip=lambda: int(sp())
fp=lambda: float(sp())
lp=lambda:list(map(int,stdin.readline().split()))
sp=lambda:stdin.readline().rstrip()
Yp=lambda:print('Yes')
Np=lambda:print('No')
inf = 1 << 60
inf = float('inf')
mod = 10 ** 9 + 7
mod = 998244353
eps = 1e-9
sortkey1 = itemgetter(0)
sortkey2 = lambda x: (x[0], x[1])



###############################################################

N = ip()
S = sp()
alpha_list_lower='abcdefghijklmnopqrstuvwxyz'
ans = []
for s in S:
    for i in range(26):
        if alpha_list_lower[i] == s:
            x = i
            break
    ans.append(alpha_list_lower[-1-x])
print(''.join(ans))
0