結果
問題 |
No.1242 高橋君とすごろく
|
ユーザー |
|
提出日時 | 2020-10-02 22:23:21 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 580 bytes |
コンパイル時間 | 1,891 ms |
コンパイル使用メモリ | 193,652 KB |
最終ジャッジ日時 | 2025-01-15 00:35:38 |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 14 WA * 10 |
ソースコード
#include <bits/stdc++.h> using namespace std; #include <math.h> #include <iomanip> #include <cstdint> template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0; } template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1; } return 0; } const int INF=1001001001; const int mod = 1000000007; int main() { int64_t N,K; cin>>N>>K; vector<int>A(K); for(int i=0;i<K;i++){ cin>>A[i]; } for(int i=0;i<K-1;i++){ if(A[i]%6==3&&A[i+1]%6==4){cout<<"No"<<endl;return 0;} } cout<<"Yes"<<endl; return 0; }