結果
問題 | No.1806 Rotating Golem |
ユーザー | 1white_princess |
提出日時 | 2022-02-08 23:39:50 |
言語 | C++14 (gcc 12.3.0 + boost 1.83.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 568 bytes |
コンパイル時間 | 1,463 ms |
コンパイル使用メモリ | 164,888 KB |
実行使用メモリ | 4,384 KB |
最終ジャッジ日時 | 2023-09-06 00:24:42 |
合計ジャッジ時間 | 2,466 ms |
ジャッジサーバーID (参考情報) |
judge14 / judge15 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 2 ms
4,380 KB |
testcase_01 | WA | - |
testcase_02 | WA | - |
testcase_03 | AC | 1 ms
4,376 KB |
testcase_04 | WA | - |
testcase_05 | WA | - |
testcase_06 | WA | - |
testcase_07 | WA | - |
testcase_08 | WA | - |
testcase_09 | WA | - |
testcase_10 | WA | - |
testcase_11 | WA | - |
testcase_12 | WA | - |
testcase_13 | WA | - |
testcase_14 | WA | - |
testcase_15 | WA | - |
ソースコード
#include <bits/stdc++.h> using namespace std; #define rep(i,a,b) for(LL i = a;i<b; i++) #define rrep(i,a,b) for(LL i = a;i>=b; i--) #define INF ((1LL<<62)-(1LL<<31)) #define ooki 9,223,372,036,854,775,807 #define tii -9,223,372,036,854,775,808 typedef long long LL; int main(){ char a,b;int c,d; cin>>a>>b; if(a=='E'){ c=1;} if(a=='W'){ c=2;} if(a=='S'){ c=3;} if(a=='N'){ c=4;} if(b=='E'){ d=1;} if(b=='W'){ d=2;} if(b=='S'){ d=3;} if(b=='N'){ d=4;} rep(i,1,4){ c++; if(c%4==d%4){cout<<i<<endl;return 0;} } }