結果

問題 No.1806 Rotating Golem
ユーザー るあせっるあせっ
提出日時 2022-03-08 04:14:26
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 413 bytes
コンパイル時間 1,639 ms
コンパイル使用メモリ 86,856 KB
実行使用メモリ 71,568 KB
最終ジャッジ日時 2023-09-30 07:57:22
合計ジャッジ時間 3,765 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 72 ms
71,280 KB
testcase_01 AC 75 ms
71,268 KB
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 AC 75 ms
71,112 KB
testcase_07 WA -
testcase_08 WA -
testcase_09 AC 76 ms
71,108 KB
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 AC 75 ms
71,328 KB
testcase_15 AC 77 ms
71,176 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#「東」「西」「南」「北」
#これらは 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)
    
    
    
0