Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  string N;
  cin >> N;
  if ( (strcmp( N[0], N[1]) == 0 && strcmp( N[0], N[2] )) == 0 || (strcmp( N[3], N[1]) == 0 && strcmp( N[3], N[2] == 0 )) ) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:15: error: invalid conversion from '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'} to 'const char*' [-fpermissive]
    7 |   if ( (strcmp( N[0], N[1]) == 0 && strcmp( N[0], N[2] )) == 0 || (strcmp( N[3], N[1]) == 0 && strcmp( N[3], N[2] == 0 )) ) {
      |         ~~~~~~^~~~~~~~~~~~~
      |               |
      |               __gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type {aka char}
In file included from /usr/include/c++/14/cstring:43,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:121,
                 from a.cc:1:
/usr/include/string.h:156:32: note:   initializing argument 1 of 'int strcmp(const char*, const char*)'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                    ~~~~~~~~~~~~^~~~
a.cc:7:15: error: invalid conversion from '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'} to 'const char*' [-fpermissive]
    7 |   if ( (strcmp( N[0], N[1]) == 0 && strcmp( N[0], N[2] )) == 0 || (strcmp( N[3], N[1]) == 0 && strcmp( N[3], N[2] == 0 )) ) {
      |         ~~~~~~^~~~~~~~~~~~~
      |               |
      |               __gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type {aka char}
/usr/include/string.h:156:50: note:   initializing argument 2 of 'int strcmp(const char*, const char*)'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                                      ~~~~~~~~~~~~^~~~
a.cc:7:43: error: invalid conversion from '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'} to 'const char*' [-fpermissive]
    7 |   if ( (strcmp( N[0], N[1]) == 0 && strcmp( N[0], N[2] )) == 0 || (strcmp( N[3], N[1]) == 0 && strcmp( N[3], N[2] == 0 )) ) {
      |                                     ~~~~~~^~~~~~~~~~~~~~
      |                                           |
      |                                           __gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type {aka char}
/usr/include/string.h:156:32: note:   initializing argument 1 of 'int strcmp(const char*, const char*)'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                    ~~~~~~~~~~~~^~~~
a.cc:7:43: error: invalid conversion from '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'} to 'const char*' [-fpermissive]
    7 |   if ( (strcmp( N[0], N[1]) == 0 && strcmp( N[0], N[2] )) == 0 || (strcmp( N[3], N[1]) == 0 && strcmp( N[3], N[2] == 0 )) ) {
      |                                     ~~~~~~^~~~~~~~~~~~~~
      |                                           |
      |                                           __gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type {aka char}
/usr/include/string.h:156:50: note:   initializing argument 2 of 'int strcmp(const char*, const char*)'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                                      ~~~~~~~~~~~~^~~~
a.cc:7:74: error: invalid conversion from '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'} to 'const char*' [-fpermissive]
    7 |   if ( (strcmp( N[0], N[1]) == 0 && strcmp( N[0], N[2] )) == 0 || (strcmp( N[3], N[1]) == 0 && strcmp( N[3], N[2] == 0 )) ) {
      |                                                                    ~~~~~~^~~~~~~~~~~~~
      |                                                                          |
      |                                                                          __gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type {aka char}
/usr/include/string.h:156:32: note:   initializing argument 1 of 'int strcmp(const char*, const char*)'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                    ~~~~~~~~~~~~^~~~
a.cc:7:74: error: invalid conversion from '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'} to 'const char*' [-fpermissive]
    7 |   if ( (strcmp( N[0], N[1]) == 0 && strcmp( N[0], N[2] )) == 0 || (strcmp( N[3], N[1]) == 0 && strcmp( N[3], N[2] == 0 )) ) {
      |                                                                    ~~~~~~^~~~~~~~~~~~~
      |                                                                          |
      |                                                                          __gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type {aka char}
/usr/include/string.h:156:50: note:   initializing argument 2 of 'int strcmp(const char*, const char*)'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                                      ~~~~~~~~~~~~^~~~
a.cc:7:102: error: invalid conversion from '__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type' {aka 'char'} to 'const char*' [-fpermissive]
    7 |   if ( (strcmp( N[0], N[1]) == 0 && strcmp( N[0], N[2] )) == 0 || (strcmp( N[3], N[1]) == 0 && strcmp( N[3], N[2] == 0 )) ) {
      |                                                                                                ~~~~~~^~~~~~~~~~~~~~~~~~~
      |                                                                                                      |
      |                                                                                                      __gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type {aka char}
a.cc:7:115: error: cannot convert 'bool' to 'const char*'
    7 |   if ( (strcmp( N[0], N[1]) == 0 && strcmp( N[0], N[2] )) == 0 || (strcmp( N[3], N[1]) == 0 && strcmp( N[3], N[2] == 0 )) ) {
/usr/include/string.h:156:50: note:   initializing argument 2 of 'int strcmp(const char*, const char*)'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                                      ~~~~~~~~~~~~^~~~