Language: C++

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

int main(){
    char SUN,MON,TUE,WED,THU,FRI,SAT;
    char S;

    cin >>S;

    if(!strcmp(S,"SUN")){
        cout << "7" << endl;
    }else if(!strcmp(S,"MON")){
        cout << "6" << endl;
    }else if(!strcmp(S,"TUE")){
        cout << "5" << endl;
    }else if(!strcmp(S,"WED")){
        cout << "4" << endl;
    }else if(!strcmp(S,"THU")){
        cout << "3" << endl;
    }else if(!strcmp(S,"FRI")){
        cout << "2" << endl;
    }else {
        cout << "1" << endl; 
    }
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:16: error: invalid conversion from 'char' to 'const char*' [-fpermissive]
   10 |     if(!strcmp(S,"SUN")){
      |                ^
      |                |
      |                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:12:22: error: invalid conversion from 'char' to 'const char*' [-fpermissive]
   12 |     }else if(!strcmp(S,"MON")){
      |                      ^
      |                      |
      |                      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:14:22: error: invalid conversion from 'char' to 'const char*' [-fpermissive]
   14 |     }else if(!strcmp(S,"TUE")){
      |                      ^
      |                      |
      |                      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:16:22: error: invalid conversion from 'char' to 'const char*' [-fpermissive]
   16 |     }else if(!strcmp(S,"WED")){
      |                      ^
      |                      |
      |                      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:18:22: error: invalid conversion from 'char' to 'const char*' [-fpermissive]
   18 |     }else if(!strcmp(S,"THU")){
      |                      ^
      |                      |
      |                      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:20:22: error: invalid conversion from 'char' to 'const char*' [-fpermissive]
   20 |     }else if(!strcmp(S,"FRI")){
      |                      ^
      |                      |
      |                      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)
      |                    ~~~~~~~~~~~~^~~~