Language: C++

#include <algorithm>
#include <bitset>
#include <tuple>
#include <cstdint>
#include <cstdio>
#include <cctype>
#include <assert.h>
#include <stdlib.h>
#include <stdio.h>
#include <cassert>
#include <cfloat>
#include <climits>
#include <cmath>
#include <complex>
#include <ctime>
#include <deque>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <iterator>
#include <list>
#include <limits>
#include <map>
#include <memory>
#include <queue>
#include <random>
#include <set>
#include <stack>
#include <string>
#include <unordered_map>
#include <unordered_set>
#include <utility>
#include <vector>
using namespace std;
using ll=long long;
//#define int long long  ←保留
#define _CRT_SECURE_NO_WARNINGS
#define rep(i, n) for (int i = 0; i < n; i++)
#define _GLIBCXX_DEBUG
const int MOD = 1e9 + 7;
const int INF = 1e18 + 9;
constexpr long double pi = 3.141592653589793238462643383279; //円周率
/*---------------------便利な関数--------------------------------------*/
int fact(int i) {       //階乗
    if (i == 0) return 1;
    return (fact(i - 1)) * i;
}
 
int gcd(int a, int b) {        //最大公約数
    if (b == 0) return a;
    return gcd(b, a % b);
}
 
int lcm(int a, int b) {      //最小公倍数
    return a * b / gcd(a, b);
}
 
int keta(int n) {        //桁数を求める
    if (n == 0) return 1;
    int count = 0;
    while (n != 0) {
        n /= 10;
        count++;
    }
    return count;
}
 
int ketasum(int n) {    //各桁の和
    int sum = 0;
    while (n != 0) {
        sum += n % 10;
        n /= 10;
    }
    return sum;
}
 
/*-------------ここまで---------------------------------------------*/
 
//C++(GCC9.2.1)
 
/*signed*/int main(void) {
  char a , b;
  cin >> a >> b;
  if ( a == ’H ’ && b == ’H ’) cout << ’H ’;
  if ( a == ’H ’ && b == ’D ’) cout << ’D ’;
  if ( a == ’D ’ && b == ’H ’) cout << ’D ’;
  if ( a == ’D ’ && b == ’D ’) cout << ’H ’;
  return 0;
}

Compiler output:
a.cc:85:13: error: extended character ’ is not valid in an identifier
   85 |   if ( a == ’H ’ && b == ’H ’) cout << ’H ’;
      |             ^
a.cc:85:16: error: extended character ’ is not valid in an identifier
   85 |   if ( a == ’H ’ && b == ’H ’) cout << ’H ’;
      |                ^
a.cc:85:26: error: extended character ’ is not valid in an identifier
   85 |   if ( a == ’H ’ && b == ’H ’) cout << ’H ’;
      |                          ^
a.cc:85:29: error: extended character ’ is not valid in an identifier
   85 |   if ( a == ’H ’ && b == ’H ’) cout << ’H ’;
      |                             ^
a.cc:85:40: error: extended character ’ is not valid in an identifier
   85 |   if ( a == ’H ’ && b == ’H ’) cout << ’H ’;
      |                                        ^
a.cc:85:43: error: extended character ’ is not valid in an identifier
   85 |   if ( a == ’H ’ && b == ’H ’) cout << ’H ’;
      |                                           ^
a.cc:86:13: error: extended character ’ is not valid in an identifier
   86 |   if ( a == ’H ’ && b == ’D ’) cout << ’D ’;
      |             ^
a.cc:86:16: error: extended character ’ is not valid in an identifier
   86 |   if ( a == ’H ’ && b == ’D ’) cout << ’D ’;
      |                ^
a.cc:86:26: error: extended character ’ is not valid in an identifier
   86 |   if ( a == ’H ’ && b == ’D ’) cout << ’D ’;
      |                          ^
a.cc:86:29: error: extended character ’ is not valid in an identifier
   86 |   if ( a == ’H ’ && b == ’D ’) cout << ’D ’;
      |                             ^
a.cc:86:40: error: extended character ’ is not valid in an identifier
   86 |   if ( a == ’H ’ && b == ’D ’) cout << ’D ’;
      |                                        ^
a.cc:86:43: error: extended character ’ is not valid in an identifier
   86 |   if ( a == ’H ’ && b == ’D ’) cout << ’D ’;
      |                                           ^
a.cc:87:13: error: extended character ’ is not valid in an identifier
   87 |   if ( a == ’D ’ && b == ’H ’) cout << ’D ’;
      |             ^
a.cc:87:16: error: extended character ’ is not valid in an identifier
   87 |   if ( a == ’D ’ && b == ’H ’) cout << ’D ’;
      |                ^
a.cc:87:26: error: extended character ’ is not valid in an identifier
   87 |   if ( a == ’D ’ && b == ’H ’) cout << ’D ’;
      |                          ^
a.cc:87:29: error: extended character ’ is not valid in an identifier
   87 |   if ( a == ’D ’ && b == ’H ’) cout << ’D ’;
      |                             ^
a.cc:87:40: error: extended character ’ is not valid in an identifier
   87 |   if ( a == ’D ’ && b == ’H ’) cout << ’D ’;
      |                                        ^
a.cc:87:43: error: extended character ’ is not valid in an identifier
   87 |   if ( a == ’D ’ && b == ’H ’) cout << ’D ’;
      |                                           ^
a.cc:88:13: error: extended character ’ is not valid in an identifier
   88 |   if ( a == ’D ’ && b == ’D ’) cout << ’H ’;
      |             ^
a.cc:88:16: error: extended character ’ is not valid in an identifier
   88 |   if ( a == ’D ’ && b == ’D ’) cout << ’H ’;
      |                ^
a.cc:88:26: error: extended character ’ is not valid in an identifier
   88 |   if ( a == ’D ’ && b == ’D ’) cout << ’H ’;
      |                          ^
a.cc:88:29: error: extended character ’ is not valid in an identifier
   88 |   if ( a == ’D ’ && b == ’D ’) cout << ’H ’;
      |                             ^
a.cc:88:40: error: extended character ’ is not valid in an identifier
   88 |   if ( a == ’D ’ && b == ’D ’) cout << ’H ’;
      |                                        ^
a.cc:88:43: error: extended character ’ is not valid in an identifier
   88 |   if ( a == ’D ’ && b == ’D ’) cout << ’H ’;
      |                                           ^
a.cc:42:22: warning: overflow in conversion from 'double' to 'int' changes value from '1.0e+18' to '2147483647' [-Woverflow]
   42 | const int INF = 1e18 + 9;
      |                 ~~~~~^~~
a.cc: In function 'int main()':
a.cc:85:13: error: '\U00002019H' was not declared in this scope
   85 |   if ( a == ’H ’ && b == ’H ’) cout << ’H ’;
      |             ^~
a.cc:85:15: error: expected ')' before '\U00002019'
   85 |   if ( a == ’H ’ && b == ’H ’) cout << ’H ’;
      |      ~        ^~
      |               )
a.cc:86:13: error: '\U00002019H' was not declared in this scope
   86 |   if ( a == ’H ’ && b == ’D ’) cout << ’D ’;
      |             ^~
a.cc:86:15: error: expected ')' before '\U00002019'
   86 |   if ( a == ’H ’ && b == ’D ’) cout << ’D ’;
      |      ~        ^~
      |               )
a.cc:86:40: error: '\U00002019D' was not declared in this scope
   86 |   if ( a == ’H ’ && b == ’D ’) cout << ’D ’;
      |                                        ^~
a.cc:87:13: error: '\U00002019D' was not declared in this scope
   87 |   if ( a == ’D ’ && b == ’H ’) cout << ’D ’;
      |             ^~
a.cc:87:15: error: expected ')' before '\U00002019'
   87 |   if ( a == ’D ’ && b == ’H ’) cout << ’D ’;
      |      ~        ^~
      |               )
a.cc:88:13: error: '\U00002019D' was not declared in this scope
   88 |   if ( a == ’D ’ && b == ’D ’) cout << ’H ’;
      |             ^~
a.cc:88:15: error: expected ')' before '\U00002019'
   88 |   if ( a == ’D ’ && b == ’D ’) cout << ’H ’;
      |      ~        ^~
      |               )
a.cc:88:40: error: '\U00002019H' was not declared in this scope
   88 |   if ( a == ’D ’ && b == ’D ’) cout << ’H ’;
      |                                        ^~