結果
問題 |
No.1806 Rotating Golem
|
ユーザー |
|
提出日時 | 2022-03-08 04:16:34 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 414 bytes |
コンパイル時間 | 164 ms |
コンパイル使用メモリ | 82,468 KB |
実行使用メモリ | 53,960 KB |
最終ジャッジ日時 | 2024-07-23 02:12:55 |
合計ジャッジ時間 | 1,433 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 6 WA * 7 |
ソースコード
# 「東」「西」「南」「北」 # これらは E, W, S, N のうちいずれか 文字であり、それぞれ「東」「西」「南」「北」に対応します。 a = ["E", "W", "S", "N"] str_1 = input() str_2 = input() if str_1 == str_2: print(0) else: soe1 = a.index(str_1) soe2 = a.index(str_2) if soe1 < soe2: print(soe2 - soe1) else: print((soe1 - soe2)+1)