結果
| 問題 | 
                            No.795 Restrictions!!!!!!!!!!!!!!
                             | 
                    
| コンテスト | |
| ユーザー | 
                             troro_kelp
                         | 
                    
| 提出日時 | 2019-03-16 01:22:50 | 
| 言語 | C++14  (gcc 13.3.0 + boost 1.87.0)  | 
                    
| 結果 | 
                             
                                AC
                                 
                             
                            
                         | 
                    
| 実行時間 | 3 ms / 2,000 ms | 
| コード長 | 926 bytes | 
| コンパイル時間 | 821 ms | 
| コンパイル使用メモリ | 95,760 KB | 
| 実行使用メモリ | 5,376 KB | 
| 最終ジャッジ日時 | 2024-07-01 22:13:53 | 
| 合計ジャッジ時間 | 1,587 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge4 / judge1 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 20 | 
ソースコード
#include <iostream>
#include <vector>
#include <list>
#include <algorithm>
#include <string>
#include <sstream>
#include <stack>
#include <iomanip>
#include <numeric>
#include <queue>
#include <climits>
#include <set>
#include <complex>
#include <cmath>
#include <cstring>
#include <map>
using namespace std;
using ll = long long;
#define MOD 1000000007
#define INF 1LL << 59
using ld = long double;
bool operator<(const pair<int, int> &a, const pair<int, int> &b)
{
    if (a.first == b.first)
    {
        return b.second > a.second;
    }
    return a.first < b.first;
}
int main()
{
    std::ios::sync_with_stdio(false);
    std::cin.tie(0);
    //cout << fixed << setprecision(5);
    string N, M;
    cin >> N >> M;
    int n = N.size(), m = M.size();
    if ((N[n - 1] - '0' + M[m - 2] - '0') % 2 == 0)
    {
        cout << "Yes" << endl;
    }
    else
    {
        cout << "No" << endl;
    }
    return 0;
}
            
            
            
        
            
troro_kelp