結果

問題 No.908 うしたぷにきあくん文字列
ユーザー skentagonskentagon
提出日時 2019-10-18 21:33:36
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 376 bytes
コンパイル時間 1,869 ms
コンパイル使用メモリ 165,372 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-06-25 15:05:13
合計ジャッジ時間 2,277 ms
ジャッジサーバーID
(参考情報)
judge5 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 18
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>

#define rep(i,n) for( int i=0; i<n; ++i )
typedef long long ll;
using namespace std;

int main(){
  string s;
  getline( cin, s );
  rep( i, s.length() ){
    //cout << s[i] << endl;
    if (i%2){
      if ( s[i] != ' ' ){ puts("No"); return 0; }
    } else {
      if ( (s[i]<'a') || ('z'<s[i]) ){ puts("No"); return 0; }
    }
  }
  puts("Yes");
}
0