where is my location


Submit solution

Points: 50
Time limit: 1.0s
Memory limit: 256M

Authors:
Problem types
Allowed languages
Java 19, Java 8

題目說明

一連串的R或L,R表示右轉,L表示左轉,起始預設值都是面向N(北方),請在輸入完成後輸出轉完後面向的方位

此題無部份給分!

輸入

一連串的R或L(Enter後即表示輸入完成,沒有限定輸入長度)

輸出

面向的方位的英文(N: 北方, E: 東方, S: 南方, W: 西方)

sample input1

RRRRRLLLLL

sample output1

N

sample input2

R

sample output2

E

Comments

There are no comments at the moment.