結果

問題 No.2482 Sandglasses
ユーザー nikoro256
提出日時 2023-09-22 23:33:31
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 290 bytes
コンパイル時間 301 ms
コンパイル使用メモリ 82,176 KB
実行使用メモリ 127,144 KB
最終ジャッジ日時 2024-11-16 22:52:28
合計ジャッジ時間 6,857 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1 WA * 2
other AC * 2 WA * 23
権限があれば一括ダウンロードができます

ソースコード

diff #

N,K,T=map(int,input().split())
a=list(map(str,input().split()))
b=list(map(int,input().split()))
c=[-1 for _ in range(N)]
T%=(2*K)
for i in range(N):
    if a[i]=='A':
        c[i]=2*K-b[i]
    else:
        c[i]=b[i]
    c[i]+=T
    c[i]%=2*K
    if c[i]>K:
        c[i]=2*K-c[i]
print(*c)
0