Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
  char a[3];
  cin>>a;
  if(str(a,'MON')==0)
  {
    cout<<6;
  }
  else if(strcmp(a,'TUE')==0)
  {
    cout<<5;
  }
  else if(strcmp(a,'WED')==0)
  {
    cout<<4;
  }
  else if(strcmp(a,'THU')==0)
  {
    cout<<3;
  }
  else if(strcmp(a,'FRI')==0)
  {
    cout<<2;
  }
  else if(strcmp(a,'SAT')==0)
  {
    cout<<1;
  }
  else if(strcmp(a,'SUN')==0)
  {
    cout<<7;
  }
  return 0;
}

Compiler output:
a.cc:7:12: warning: multi-character character constant [-Wmultichar]
    7 |   if(str(a,'MON')==0)
      |            ^~~~~
a.cc:11:20: warning: multi-character character constant [-Wmultichar]
   11 |   else if(strcmp(a,'TUE')==0)
      |                    ^~~~~
a.cc:15:20: warning: multi-character character constant [-Wmultichar]
   15 |   else if(strcmp(a,'WED')==0)
      |                    ^~~~~
a.cc:19:20: warning: multi-character character constant [-Wmultichar]
   19 |   else if(strcmp(a,'THU')==0)
      |                    ^~~~~
a.cc:23:20: warning: multi-character character constant [-Wmultichar]
   23 |   else if(strcmp(a,'FRI')==0)
      |                    ^~~~~
a.cc:27:20: warning: multi-character character constant [-Wmultichar]
   27 |   else if(strcmp(a,'SAT')==0)
      |                    ^~~~~
a.cc:31:20: warning: multi-character character constant [-Wmultichar]
   31 |   else if(strcmp(a,'SUN')==0)
      |                    ^~~~~
a.cc: In function 'int main()':
a.cc:7:6: error: 'str' was not declared in this scope; did you mean 'std'?
    7 |   if(str(a,'MON')==0)
      |      ^~~
      |      std
a.cc:11:20: error: invalid conversion from 'int' to 'const char*' [-fpermissive]
   11 |   else if(strcmp(a,'TUE')==0)
      |                    ^~~~~
      |                    |
      |                    int
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:50: note:   initializing argument 2 of 'int strcmp(const char*, const char*)'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                                      ~~~~~~~~~~~~^~~~
a.cc:15:20: error: invalid conversion from 'int' to 'const char*' [-fpermissive]
   15 |   else if(strcmp(a,'WED')==0)
      |                    ^~~~~
      |                    |
      |                    int
/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:19:20: error: invalid conversion from 'int' to 'const char*' [-fpermissive]
   19 |   else if(strcmp(a,'THU')==0)
      |                    ^~~~~
      |                    |
      |                    int
/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:23:20: error: invalid conversion from 'int' to 'const char*' [-fpermissive]
   23 |   else if(strcmp(a,'FRI')==0)
      |                    ^~~~~
      |                    |
      |                    int
/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:27:20: error: invalid conversion from 'int' to 'const char*' [-fpermissive]
   27 |   else if(strcmp(a,'SAT')==0)
      |                    ^~~~~
      |                    |
      |                    int
/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:31:20: error: invalid conversion from 'int' to 'const char*' [-fpermissive]
   31 |   else if(strcmp(a,'SUN')==0)
      |                    ^~~~~
      |                    |
      |                    int
/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)
      |                                      ~~~~~~~~~~~~^~~~