結果
問題 |
No.908 うしたぷにきあくん文字列
|
ユーザー |
|
提出日時 | 2019-10-20 04:10:47 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 3 ms / 2,000 ms |
コード長 | 447 bytes |
コンパイル時間 | 2,518 ms |
コンパイル使用メモリ | 191,932 KB |
最終ジャッジ日時 | 2025-01-08 00:03:00 |
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 18 |
ソースコード
#define _USE_MATH_DEFINES #include <bits/stdc++.h> using namespace std; signed main() { ios::sync_with_stdio(false); cin.tie(0); string s; getline(cin, s); for (int i = 0; i < (int) s.size(); i++) { if (i % 2 == 0) { if ('a' > s[i] || s[i] > 'z') { cout << "No\n"; return 0; } } else { if (s[i] != ' ') { cout << "No\n"; return 0; } } } cout << "Yes\n"; return 0; }