criyle/codenet-compile-errors huggingface dataset:
Language: C++

#include<iostream>
using namespace std;
int main()
{
      int SAT;
      int SUN;
      
  cout<<"The day after" << SAT <<"is";
  return "SUN";
  cout<<"7 days after" << SUN << "is";
  return;"SUN"
  
        
    
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:10: error: invalid conversion from 'const char*' to 'int' [-fpermissive]
    9 |   return "SUN";
      |          ^~~~~
      |          |
      |          const char*
a.cc:11:3: error: return-statement with no value, in function returning 'int' [-fpermissive]
   11 |   return;"SUN"
      |   ^~~~~~
a.cc:11:15: error: expected ';' before '}' token
   11 |   return;"SUN"
      |               ^
      |               ;
......
   15 | }
      | ~
Language: C++

#include<iostream>
using namespace std;
int main()
{
      int SAT;
      int SUN;
        int S='SUN''MON''TUE''WED''THU''FRI''SAT''SUN';
  cout<< SAT+1==SUN <<endl;
  cout<< SUN+7==SUN << endl;
  
        
        return 0;
}

Compiler output:
a.cc:7:15: warning: multi-character character constant [-Wmultichar]
    7 |         int S='SUN''MON''TUE''WED''THU''FRI''SAT''SUN';
      |               ^~~~~
a.cc:7:20: warning: multi-character character constant [-Wmultichar]
    7 |         int S='SUN''MON''TUE''WED''THU''FRI''SAT''SUN';
      |                    ^~~~~
a.cc:7:25: warning: multi-character character constant [-Wmultichar]
    7 |         int S='SUN''MON''TUE''WED''THU''FRI''SAT''SUN';
      |                         ^~~~~
a.cc:7:30: warning: multi-character character constant [-Wmultichar]
    7 |         int S='SUN''MON''TUE''WED''THU''FRI''SAT''SUN';
      |                              ^~~~~
a.cc:7:35: warning: multi-character character constant [-Wmultichar]
    7 |         int S='SUN''MON''TUE''WED''THU''FRI''SAT''SUN';
      |                                   ^~~~~
a.cc:7:40: warning: multi-character character constant [-Wmultichar]
    7 |         int S='SUN''MON''TUE''WED''THU''FRI''SAT''SUN';
      |                                        ^~~~~
a.cc:7:45: warning: multi-character character constant [-Wmultichar]
    7 |         int S='SUN''MON''TUE''WED''THU''FRI''SAT''SUN';
      |                                             ^~~~~
a.cc:7:50: warning: multi-character character constant [-Wmultichar]
    7 |         int S='SUN''MON''TUE''WED''THU''FRI''SAT''SUN';
      |                                                  ^~~~~
a.cc: In function 'int main()':
a.cc:7:20: error: expected ',' or ';' before '\x4d4f4e'
    7 |         int S='SUN''MON''TUE''WED''THU''FRI''SAT''SUN';
      |                    ^~~~~
a.cc:8:21: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
    8 |   cout<< SAT+1==SUN <<endl;
      |                 ~~~~^~~~~~
a.cc:9:21: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
    9 |   cout<< SUN+7==SUN << endl;
      |                 ~~~~^~~~~~~
Language: C++

#include<iostream>
using namespace std;
int main()
{
      int SAT+1==SUN
      int SUN+7==SUN
        return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:14: error: expected initializer before '+' token
    5 |       int SAT+1==SUN
      |              ^
Language: C++

#include <iostream>
#include <cstring>
using namespace std;
int main(){
  char s[3];
  cin >> s;
  if(!strcmp(s, "SUN") cout << 7;
  else if(!strcmp(s, "MON")) cout << 6;
  else if(!strcmp(s, "TUE") cout << 5;
  else if(!strcmp(s, "WED") cout << 4;
  else if(!strcmp(s, "THU") cout << 3;
  else if(!strcmp(s, "FRI") cout << 2;
  else cout << 1;
  cout << endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:23: error: expected ';' before 'cout'
    7 |   if(!strcmp(s, "SUN") cout << 7;
      |                       ^~~~~
      |                       ;
a.cc:8:3: error: expected primary-expression before 'else'
    8 |   else if(!strcmp(s, "MON")) cout << 6;
      |   ^~~~
a.cc:7:34: error: expected ')' before 'else'
    7 |   if(!strcmp(s, "SUN") cout << 7;
      |     ~                            ^
      |                                  )
    8 |   else if(!strcmp(s, "MON")) cout << 6;
      |   ~~~~                            
a.cc:9:28: error: expected ';' before 'cout'
    9 |   else if(!strcmp(s, "TUE") cout << 5;
      |                            ^~~~~
      |                            ;
a.cc:10:3: error: expected primary-expression before 'else'
   10 |   else if(!strcmp(s, "WED") cout << 4;
      |   ^~~~
a.cc:9:39: error: expected ')' before 'else'
    9 |   else if(!strcmp(s, "TUE") cout << 5;
      |          ~                            ^
      |                                       )
   10 |   else if(!strcmp(s, "WED") cout << 4;
      |   ~~~~                                 
a.cc:11:28: error: expected ';' before 'cout'
   11 |   else if(!strcmp(s, "THU") cout << 3;
      |                            ^~~~~
      |                            ;
a.cc:12:3: error: expected primary-expression before 'else'
   12 |   else if(!strcmp(s, "FRI") cout << 2;
      |   ^~~~
a.cc:11:39: error: expected ')' before 'else'
   11 |   else if(!strcmp(s, "THU") cout << 3;
      |          ~                            ^
      |                                       )
   12 |   else if(!strcmp(s, "FRI") cout << 2;
      |   ~~~~
Language: C++

#include <iostream>
using namespace std;
int main(){
  char s[3];
  cin >> s;
  if(!strcmp(s, "SUN") cout << 7;
  else if(!strcmp(s, "MON")) cout << 6;
  else if(!strcmp(s, "TUE") cout << 5;
  else if(!strcmp(s, "WED") cout << 4;
  else if(!strcmp(s, "THU") cout << 3;
  else if(!strcmp(s, "FRI") cout << 2;
  else cout << 1;
  cout << endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:7: error: 'strcmp' was not declared in this scope
    6 |   if(!strcmp(s, "SUN") cout << 7;
      |       ^~~~~~
a.cc:2:1: note: 'strcmp' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    1 | #include <iostream>
  +++ |+#include <cstring>
    2 | using namespace std;
a.cc:7:3: error: expected primary-expression before 'else'
    7 |   else if(!strcmp(s, "MON")) cout << 6;
      |   ^~~~
a.cc:6:34: error: expected ')' before 'else'
    6 |   if(!strcmp(s, "SUN") cout << 7;
      |     ~                            ^
      |                                  )
    7 |   else if(!strcmp(s, "MON")) cout << 6;
      |   ~~~~                            
a.cc:9:3: error: expected primary-expression before 'else'
    9 |   else if(!strcmp(s, "WED") cout << 4;
      |   ^~~~
a.cc:8:39: error: expected ')' before 'else'
    8 |   else if(!strcmp(s, "TUE") cout << 5;
      |          ~                            ^
      |                                       )
    9 |   else if(!strcmp(s, "WED") cout << 4;
      |   ~~~~                                 
a.cc:11:3: error: expected primary-expression before 'else'
   11 |   else if(!strcmp(s, "FRI") cout << 2;
      |   ^~~~
a.cc:10:39: error: expected ')' before 'else'
   10 |   else if(!strcmp(s, "THU") cout << 3;
      |          ~                            ^
      |                                       )
   11 |   else if(!strcmp(s, "FRI") cout << 2;
      |   ~~~~
Language: C

#include<stdio.h>
#include<string.h>
 
int main(){
	int a;
  	char s[26]="abcdefghijklmnopqrstuvwxyz";
  	char h[10002]; 	
  	scanf("%d %s",a,h);
	
  	for(int i=0, i<strlen(h),i++){
      for(int j=0, j<26, j++){
      	if(h[i]==s[j]){
        	printf("%c", h[i+a]);
        }
      }
    }
  
  	printf("\n");
  
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:10:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   10 |         for(int i=0, i<strlen(h),i++){
      |                       ^
main.c:20:3: error: expected expression before 'return'
   20 |   return 0;
      |   ^~~~~~
main.c:21:1: error: expected expression before '}' token
   21 | }
      | ^
Language: C

#include<stdio.h>
#include<string.h>
 
int main(){
	int a;
  	char s[26]="abcdefghijklmnopqrstuvwxyz";
  	char h[10002]; 	
  	scanf("%d %s",&a,h);
	
  	for(i=0, i<strlen(h),i++){
      for(j=0, j<26, j++){
      	if(h[i]==s[j]){
        	printf("%c", h[i+a]);
        }
      }
    }
  
  	printf("\n");
  
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:10:13: error: 'i' undeclared (first use in this function)
   10 |         for(i=0, i<strlen(h),i++){
      |             ^
main.c:10:13: note: each undeclared identifier is reported only once for each function it appears in
main.c:10:33: error: expected ';' before ')' token
   10 |         for(i=0, i<strlen(h),i++){
      |                                 ^
      |                                 ;
main.c:10:33: error: expected expression before ')' token
main.c:11:11: error: 'j' undeclared (first use in this function)
   11 |       for(j=0, j<26, j++){
      |           ^
main.c:11:25: error: expected ';' before ')' token
   11 |       for(j=0, j<26, j++){
      |                         ^
      |                         ;
main.c:11:25: error: expected expression before ')' token
Language: C++

#include <iostream>
using namespace std ;
int main()
{
  char day ;
  cin >> day ;

  char week[7] = { "SUN","MON","TUE","WED","THU","FRI","SAT" } ;

  int i ;
  for( i = 0 ; i < 7 ; i++ ){
    if( day == week[i] ){
      cout <<  7 - i ;
    }
  }
  
  return 0 ;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:62: error: too many initializers for 'char [7]'
    8 |   char week[7] = { "SUN","MON","TUE","WED","THU","FRI","SAT" } ;
      |                                                              ^
Language: C

#include<stdio.h>
 
int main(){
	int a;
  	char s[5];
  	scanf("%s", s);
	if(strcmp(s,"SUN")==0){  
  	a=7;
    } else if(strcmp(s,"MON")==0){
    a=6;  
    } else if(strcmp(s,"TUE")==0){
    a=5;  
    } else if(strcmp(s,"WED")==0){
    a=4;  
    } else if(strcmp(s,"THU")==0){
    a=3;  
    } else if(strcmp(s,"FRI")==0){
    a=2;  
    } else if(strcmp(s,"SAT")==0){
    a=1;  
      
  	printf("%d",a);
  
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:7:12: error: implicit declaration of function 'strcmp' [-Wimplicit-function-declaration]
    7 |         if(strcmp(s,"SUN")==0){
      |            ^~~~~~
main.c:2:1: note: include '<string.h>' or provide a declaration of 'strcmp'
    1 | #include<stdio.h>
  +++ |+#include <string.h>
    2 | 
main.c:25:1: error: expected declaration or statement at end of input
   25 | }
      | ^
Language: C

clude<stdio.h>
 
int main(){
	int a=0;
  	char s[5];
  	scanf("%s", s);
    if(s=="SUN"){
    a=7;
    } else if(s=="MON"){
    a=6;  
    } else if(s=="TUE"){
    a=5;
    } else if(s=="WED"){
    a=4;
    } else if(s=="THU"){
    a=3;
    } else if(s=="FRI"){
    a=2;
    } else if(s=="SAT"){
    a=1;
    } 
      
  	printf("%d",a);
}

Compiler output:
main.c:1:6: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    1 | clude<stdio.h>
      |      ^
Language: Java

public class Main {
    public static void main(String[] args) {
    	ACBC146V.A();
    }
}

class ACBC146V {
	static Scanner sc = new Scanner(System.in);
	static void A() {
		String s = sc.next();
		final String[] WEEK = new String[]{"SUN", "MON", "TUE", "WED", "THU", "FRI", "SAT"};
		for (int i = 0; i < WEEK.length; i++) {
			if(WEEK[i].equals(s)) {
				System.out.println(7 - i);
			}
		}
	}
}

Compiler output:
Main.java:8: error: cannot find symbol
	static Scanner sc = new Scanner(System.in);
	       ^
  symbol:   class Scanner
  location: class ACBC146V
Main.java:8: error: cannot find symbol
	static Scanner sc = new Scanner(System.in);
	                        ^
  symbol:   class Scanner
  location: class ACBC146V
2 errors
Language: C

#include<stdio.h>
int main (void)
{
  char s;
  int n;
  scanf("%c",&s);
  switch(s)
    case "SUN":
  		n=7;
  		break;
    case "MAN":
        n=6;
  		break;
    case "TUE":
        n=5;
  		break;
    case "WED":
        n=4;
  		break;
    case "THU":
        n=3;
  		break;
    case "FRI":
        n=2;
  		break;
    case "SAT":
        n=1;
  		break;
  printf("%s",n);

Compiler output:
main.c: In function 'main':
main.c:8:5: error: pointers are not permitted as case values
    8 |     case "SUN":
      |     ^~~~
main.c:10:17: error: break statement not within loop or switch
   10 |                 break;
      |                 ^~~~~
main.c:11:5: error: case label not within a switch statement
   11 |     case "MAN":
      |     ^~~~
main.c:13:17: error: break statement not within loop or switch
   13 |                 break;
      |                 ^~~~~
main.c:14:5: error: case label not within a switch statement
   14 |     case "TUE":
      |     ^~~~
main.c:16:17: error: break statement not within loop or switch
   16 |                 break;
      |                 ^~~~~
main.c:17:5: error: case label not within a switch statement
   17 |     case "WED":
      |     ^~~~
main.c:19:17: error: break statement not within loop or switch
   19 |                 break;
      |                 ^~~~~
main.c:20:5: error: case label not within a switch statement
   20 |     case "THU":
      |     ^~~~
main.c:22:17: error: break statement not within loop or switch
   22 |                 break;
      |                 ^~~~~
main.c:23:5: error: case label not within a switch statement
   23 |     case "FRI":
      |     ^~~~
main.c:25:17: error: break statement not within loop or switch
   25 |                 break;
      |                 ^~~~~
main.c:26:5: error: case label not within a switch statement
   26 |     case "SAT":
      |     ^~~~
main.c:28:17: error: break statement not within loop or switch
   28 |                 break;
      |                 ^~~~~
main.c:29:3: error: expected declaration or statement at end of input
   29 |   printf("%s",n);
      |   ^~~~~~
Language: C++

#include <iomanip>
using namespace std;
 
int main() {
  string s;
  cin >> s;
  if(s == "SUN") cout << 7 << endl;
  if(s == "MON") cout << 6 << endl;
  if(s == "TUE") cout << 5 << endl;
  if(s == "WED") cout << 4 << endl;
  if(s == "THU") cout << 3 << endl;
  if(s == "FRI") cout << 2 << endl;
  if(s == "SAT") cout << 1 << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:3: error: 'cin' was not declared in this scope
    6 |   cin >> s;
      |   ^~~
a.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    1 | #include <iomanip>
  +++ |+#include <iostream>
    2 | using namespace std;
a.cc:7:18: error: 'cout' was not declared in this scope
    7 |   if(s == "SUN") cout << 7 << endl;
      |                  ^~~~
a.cc:7:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:8:18: error: 'cout' was not declared in this scope
    8 |   if(s == "MON") cout << 6 << endl;
      |                  ^~~~
a.cc:8:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:9:18: error: 'cout' was not declared in this scope
    9 |   if(s == "TUE") cout << 5 << endl;
      |                  ^~~~
a.cc:9:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:10:18: error: 'cout' was not declared in this scope
   10 |   if(s == "WED") cout << 4 << endl;
      |                  ^~~~
a.cc:10:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:11:18: error: 'cout' was not declared in this scope
   11 |   if(s == "THU") cout << 3 << endl;
      |                  ^~~~
a.cc:11:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:12:18: error: 'cout' was not declared in this scope
   12 |   if(s == "FRI") cout << 2 << endl;
      |                  ^~~~
a.cc:12:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:13:18: error: 'cout' was not declared in this scope
   13 |   if(s == "SAT") cout << 1 << endl;
      |                  ^~~~
a.cc:13:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
Language: C++

#include <iostream>
#include<map>
#include<string>
 
using namespace std;
 
map<string,int> tab;
tab["SUN"]=7;
tab["MON"]=6;
tab["TUE"]=5;
tab["WED"]=4;
tab["THU"]=3;
tab["FRI"]=2;
tab["SAT"]=1;
int main()
{
  string s;
cin >> s;
cout<<tab[s];
return 0;
}
  

Compiler output:
a.cc:8:1: error: 'tab' does not name a type
    8 | tab["SUN"]=7;
      | ^~~
a.cc:9:1: error: 'tab' does not name a type
    9 | tab["MON"]=6;
      | ^~~
a.cc:10:1: error: 'tab' does not name a type
   10 | tab["TUE"]=5;
      | ^~~
a.cc:11:1: error: 'tab' does not name a type
   11 | tab["WED"]=4;
      | ^~~
a.cc:12:1: error: 'tab' does not name a type
   12 | tab["THU"]=3;
      | ^~~
a.cc:13:1: error: 'tab' does not name a type
   13 | tab["FRI"]=2;
      | ^~~
a.cc:14:1: error: 'tab' does not name a type
   14 | tab["SAT"]=1;
      | ^~~
Language: C++

#include <bitts/stdc++.h>
 
using namespace std;
 
map<string,int> tab;
tab["SUN"]=7;
tab["MON"]=6;
tab["TUE"]=5;
tab["WED"]=4;
tab["THU"]=3;
tab["FRI"]=2;
tab["SAT"]=1;
int main()
{
  string s;
cin >> s;
cout<<tab[s];
return 0;
}
  

Compiler output:
a.cc:1:10: fatal error: bitts/stdc++.h: No such file or directory
    1 | #include <bitts/stdc++.h>
      |          ^~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <iostream>
#include <map>
#include <string>
using namespace std;

map<string,int> tab;
tab.insert({"SUN",7});
tab.insert({"MON",6});
tab.insert({"TUE",5});
tab.insert({"WED",4});
tab.insert({"THU",3});
tab.insert({"FRI",2});
tab.insert({"SAT",1});
int main()
{
  string s;
cin >> s;
cout<<tab[s];
return 0;
}
  


Compiler output:
a.cc:7:1: error: 'tab' does not name a type
    7 | tab.insert({"SUN",7});
      | ^~~
a.cc:7:21: error: expected unqualified-id before ')' token
    7 | tab.insert({"SUN",7});
      |                     ^
a.cc:8:1: error: 'tab' does not name a type
    8 | tab.insert({"MON",6});
      | ^~~
a.cc:8:21: error: expected unqualified-id before ')' token
    8 | tab.insert({"MON",6});
      |                     ^
a.cc:9:1: error: 'tab' does not name a type
    9 | tab.insert({"TUE",5});
      | ^~~
a.cc:9:21: error: expected unqualified-id before ')' token
    9 | tab.insert({"TUE",5});
      |                     ^
a.cc:10:1: error: 'tab' does not name a type
   10 | tab.insert({"WED",4});
      | ^~~
a.cc:10:21: error: expected unqualified-id before ')' token
   10 | tab.insert({"WED",4});
      |                     ^
a.cc:11:1: error: 'tab' does not name a type
   11 | tab.insert({"THU",3});
      | ^~~
a.cc:11:21: error: expected unqualified-id before ')' token
   11 | tab.insert({"THU",3});
      |                     ^
a.cc:12:1: error: 'tab' does not name a type
   12 | tab.insert({"FRI",2});
      | ^~~
a.cc:12:21: error: expected unqualified-id before ')' token
   12 | tab.insert({"FRI",2});
      |                     ^
a.cc:13:1: error: 'tab' does not name a type
   13 | tab.insert({"SAT",1});
      | ^~~
a.cc:13:21: error: expected unqualified-id before ')' token
   13 | tab.insert({"SAT",1});
      |                     ^
Language: C++

#include <iostream>
#include <map>
#include <string>
using namespace std;

map<string,int> tab;
tab["SUN"].insert(7);
tab["MON"].insert(6);
tab["TUE"].insert(5);
tab["WED"].insert(4);
tab["THU"].insert(3);
tab["FRI"].insert(2);
tab["SAT"].insert(1);
int main()
{
  string s;
cin >> s;
cout<<tab[s];
return 0;
}
  


Compiler output:
a.cc:7:1: error: 'tab' does not name a type
    7 | tab["SUN"].insert(7);
      | ^~~
a.cc:8:1: error: 'tab' does not name a type
    8 | tab["MON"].insert(6);
      | ^~~
a.cc:9:1: error: 'tab' does not name a type
    9 | tab["TUE"].insert(5);
      | ^~~
a.cc:10:1: error: 'tab' does not name a type
   10 | tab["WED"].insert(4);
      | ^~~
a.cc:11:1: error: 'tab' does not name a type
   11 | tab["THU"].insert(3);
      | ^~~
a.cc:12:1: error: 'tab' does not name a type
   12 | tab["FRI"].insert(2);
      | ^~~
a.cc:13:1: error: 'tab' does not name a type
   13 | tab["SAT"].insert(1);
      | ^~~
Language: C++

#include <iostream>

using namespace std;

map<string,int> tab;
tab["SUN"].insert(7);
tab["MON"].insert(6);
tab["TUE"].insert(5);
tab["WED"].insert(4);
tab["THU"].insert(3);
tab["FRI"].insert(2);
tab["SAT"].insert(1);
int main()
{
  string s;
cin >> s;
cout<<tab[s];
return 0;
}
  


Compiler output:
a.cc:5:1: error: 'map' does not name a type
    5 | map<string,int> tab;
      | ^~~
a.cc:6:1: error: 'tab' does not name a type
    6 | tab["SUN"].insert(7);
      | ^~~
a.cc:7:1: error: 'tab' does not name a type
    7 | tab["MON"].insert(6);
      | ^~~
a.cc:8:1: error: 'tab' does not name a type
    8 | tab["TUE"].insert(5);
      | ^~~
a.cc:9:1: error: 'tab' does not name a type
    9 | tab["WED"].insert(4);
      | ^~~
a.cc:10:1: error: 'tab' does not name a type
   10 | tab["THU"].insert(3);
      | ^~~
a.cc:11:1: error: 'tab' does not name a type
   11 | tab["FRI"].insert(2);
      | ^~~
a.cc:12:1: error: 'tab' does not name a type
   12 | tab["SAT"].insert(1);
      | ^~~
a.cc: In function 'int main()':
a.cc:17:7: error: 'tab' was not declared in this scope
   17 | cout<<tab[s];
      |       ^~~
Language: C++

#include <bitts/stdc++.h>

using namespace std;

map<string,int> tab;
tab["SUN"].insert(7);
tab["MON"].insert(6);
tab["TUE"].insert(5);
tab["WED"].insert(4);
tab["THU"].insert(3);
tab["FRI"].insert(2);
tab["SAT"].insert(1);
int main()
{
  string s;
cin >> s;
cout<<tab[s];
return 0;
}
  


Compiler output:
a.cc:1:10: fatal error: bitts/stdc++.h: No such file or directory
    1 | #include <bitts/stdc++.h>
      |          ^~~~~~~~~~~~~~~~
compilation terminated.
Language: Java

import java.util.*;
import java.io.*;

public class Practice{
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String s = sc.next();
		if(s.equals("SUN")){
			System.out.println("7");
		}
		if(s.equals("MON")){
			System.out.println("6");
		}
		if(s.equals("TUE")){
			System.out.println("5");
		}
		if(s.equals("WED")){
			System.out.println("4");
		}
		if(s.equals("THU")){
			System.out.println("3");
		}
		if(s.equals("FRI")){
			System.out.println("2");
		}
		if(s.equals("SAT")){
			System.out.println("1");
		}
	}
		
		
}

Compiler output:
Main.java:4: error: class Practice is public, should be declared in a file named Practice.java
public class Practice{
       ^
1 error
Language: C++

#include <bits/stdc++.h>
#define pb push_back
#define ll long long
#define pi 3.14
using namespace std;
typedef pair<int,int> pii;
typedef pair<long long,long long> pll;
typedef pair<long long,int> pli;
typedef pair<int,long long> pil;
const int INF=1000000007;
const int MOD=1000000007;
const int nmax=10123;


char in,s[7][]={'SUN','MON','TUE','WED','THU','FRI','SAT'};

int main()
{
    scanf("%s",in);
    for(int i=0;;++i){
        if(strcmp(in,s[i])==0){
            printf("%d\n",7-i);
            break;
        }
    }
    return 0;
}


Compiler output:
a.cc:15:17: warning: multi-character character constant [-Wmultichar]
   15 | char in,s[7][]={'SUN','MON','TUE','WED','THU','FRI','SAT'};
      |                 ^~~~~
a.cc:15:23: warning: multi-character character constant [-Wmultichar]
   15 | char in,s[7][]={'SUN','MON','TUE','WED','THU','FRI','SAT'};
      |                       ^~~~~
a.cc:15:29: warning: multi-character character constant [-Wmultichar]
   15 | char in,s[7][]={'SUN','MON','TUE','WED','THU','FRI','SAT'};
      |                             ^~~~~
a.cc:15:35: warning: multi-character character constant [-Wmultichar]
   15 | char in,s[7][]={'SUN','MON','TUE','WED','THU','FRI','SAT'};
      |                                   ^~~~~
a.cc:15:41: warning: multi-character character constant [-Wmultichar]
   15 | char in,s[7][]={'SUN','MON','TUE','WED','THU','FRI','SAT'};
      |                                         ^~~~~
a.cc:15:47: warning: multi-character character constant [-Wmultichar]
   15 | char in,s[7][]={'SUN','MON','TUE','WED','THU','FRI','SAT'};
      |                                               ^~~~~
a.cc:15:53: warning: multi-character character constant [-Wmultichar]
   15 | char in,s[7][]={'SUN','MON','TUE','WED','THU','FRI','SAT'};
      |                                                     ^~~~~
a.cc:15:9: error: declaration of 's' as multidimensional array must have bounds for all dimensions except the first
   15 | char in,s[7][]={'SUN','MON','TUE','WED','THU','FRI','SAT'};
      |         ^
a.cc: In function 'int main()':
a.cc:21:22: error: 's' was not declared in this scope
   21 |         if(strcmp(in,s[i])==0){
      |                      ^
Language: C

#include <stdio.h>
#include <string.h>

int main(void) {
  string date;
  int res;
  char[4] buf;
  fgets(buf, sizeof buf, stdin);
  sscanf(buf, "%s", &date);
  switch(date){
    case "SUN":
      res = 7; break;
    case "MON":
      res = 6; break;
    case "TUE":
      res = 5; break;
    case "WED":
      res = 4; break;
    case "THU":
      res = 3; break;
    case "FRI":
      res = 2; break;
    case "SAT":
      res = 1; break;
    default:
      res = 0; break;
  }
  printf("%d",res);

Compiler output:
main.c: In function 'main':
main.c:5:3: error: unknown type name 'string'; did you mean 'stdin'?
    5 |   string date;
      |   ^~~~~~
      |   stdin
main.c:7:7: error: expected identifier or '(' before '[' token
    7 |   char[4] buf;
      |       ^
main.c:8:9: error: 'buf' undeclared (first use in this function)
    8 |   fgets(buf, sizeof buf, stdin);
      |         ^~~
main.c:8:9: note: each undeclared identifier is reported only once for each function it appears in
main.c:11:5: error: pointers are not permitted as case values
   11 |     case "SUN":
      |     ^~~~
main.c:13:5: error: pointers are not permitted as case values
   13 |     case "MON":
      |     ^~~~
main.c:15:5: error: pointers are not permitted as case values
   15 |     case "TUE":
      |     ^~~~
main.c:17:5: error: pointers are not permitted as case values
   17 |     case "WED":
      |     ^~~~
main.c:19:5: error: pointers are not permitted as case values
   19 |     case "THU":
      |     ^~~~
main.c:21:5: error: pointers are not permitted as case values
   21 |     case "FRI":
      |     ^~~~
main.c:23:5: error: pointers are not permitted as case values
   23 |     case "SAT":
      |     ^~~~
main.c:28:3: error: expected declaration or statement at end of input
   28 |   printf("%d",res);
      |   ^~~~~~
Language: C++

#include <iostream>
#include <string>
#include <algorithm>
#include<math.h>
using namespace std;

int main(){
    long int A,B,X;
    cin >> A >> B >> X;
    if(A + B > X){
        cout << 0;
        return 0;
    }
    if(A*1000000000+B*10<X){
        cout << 1000000000;
        return 0;
    }
    int d=1;
    while(A*pow(10,d-1)+B*d<=X) d++;
    long int N = pow(10,d-2);
    long int temp = pow(10,d-1)
    while(N<temp){
        if(A*N+B*(d-1)<=X) N++;
        else break;
    }
    cout << N-1;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:22:5: error: expected ',' or ';' before 'while'
   22 |     while(N<temp){
      |     ^~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  string S;
  cin>>S;
  if(S==SUN)cout<<7<<endl;
  if(S==MON)cout<<6<<endl;
    if(S==TUE)cout<<5<<endl;
    if(S==WED)cout<<4<<endl;
    if(S==THU)cout<<3<<endl;
   if(S==FRI)cout<<2<<endl;
    else cout<<1<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:9: error: 'SUN' was not declared in this scope
    7 |   if(S==SUN)cout<<7<<endl;
      |         ^~~
a.cc:8:9: error: 'MON' was not declared in this scope
    8 |   if(S==MON)cout<<6<<endl;
      |         ^~~
a.cc:9:11: error: 'TUE' was not declared in this scope
    9 |     if(S==TUE)cout<<5<<endl;
      |           ^~~
a.cc:10:11: error: 'WED' was not declared in this scope
   10 |     if(S==WED)cout<<4<<endl;
      |           ^~~
a.cc:11:11: error: 'THU' was not declared in this scope
   11 |     if(S==THU)cout<<3<<endl;
      |           ^~~
a.cc:12:10: error: 'FRI' was not declared in this scope
   12 |    if(S==FRI)cout<<2<<endl;
      |          ^~~
Language: C++

include <iostream>
using namespace std;
int main(){
  string S;
  cin >> S;
  if(S == SUN){
    cout << 7<< endl;
  }
  if(S == MON){
    cout << 6<< endl;
  }
  if(S == TUE){
    cout << 5<< endl;
  }
  if(S == WED){
    cout << 4<< endl;
  }
  if(S == THU){
    cout << 3<< endl;
  }
  if(S == FRI){
    cout << 2<< endl;
  }
  if(S == SAT){
    cout << 1<< endl;
  }
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include <iostream>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:4:3: error: 'string' was not declared in this scope
    4 |   string S;
      |   ^~~~~~
a.cc:5:3: error: 'cin' was not declared in this scope
    5 |   cin >> S;
      |   ^~~
a.cc:5:10: error: 'S' was not declared in this scope
    5 |   cin >> S;
      |          ^
a.cc:6:11: error: 'SUN' was not declared in this scope
    6 |   if(S == SUN){
      |           ^~~
a.cc:7:5: error: 'cout' was not declared in this scope
    7 |     cout << 7<< endl;
      |     ^~~~
a.cc:7:17: error: 'endl' was not declared in this scope
    7 |     cout << 7<< endl;
      |                 ^~~~
a.cc:9:11: error: 'MON' was not declared in this scope
    9 |   if(S == MON){
      |           ^~~
a.cc:10:5: error: 'cout' was not declared in this scope
   10 |     cout << 6<< endl;
      |     ^~~~
a.cc:10:17: error: 'endl' was not declared in this scope
   10 |     cout << 6<< endl;
      |                 ^~~~
a.cc:12:11: error: 'TUE' was not declared in this scope
   12 |   if(S == TUE){
      |           ^~~
a.cc:13:5: error: 'cout' was not declared in this scope
   13 |     cout << 5<< endl;
      |     ^~~~
a.cc:13:17: error: 'endl' was not declared in this scope
   13 |     cout << 5<< endl;
      |                 ^~~~
a.cc:15:11: error: 'WED' was not declared in this scope
   15 |   if(S == WED){
      |           ^~~
a.cc:16:5: error: 'cout' was not declared in this scope
   16 |     cout << 4<< endl;
      |     ^~~~
a.cc:16:17: error: 'endl' was not declared in this scope
   16 |     cout << 4<< endl;
      |                 ^~~~
a.cc:18:11: error: 'THU' was not declared in this scope
   18 |   if(S == THU){
      |           ^~~
a.cc:19:5: error: 'cout' was not declared in this scope
   19 |     cout << 3<< endl;
      |     ^~~~
a.cc:19:17: error: 'endl' was not declared in this scope
   19 |     cout << 3<< endl;
      |                 ^~~~
a.cc:21:11: error: 'FRI' was not declared in this scope
   21 |   if(S == FRI){
      |           ^~~
a.cc:22:5: error: 'cout' was not declared in this scope
   22 |     cout << 2<< endl;
      |     ^~~~
a.cc:22:17: error: 'endl' was not declared in this scope
   22 |     cout << 2<< endl;
      |                 ^~~~
a.cc:24:11: error: 'SAT' was not declared in this scope
   24 |   if(S == SAT){
      |           ^~~
a.cc:25:5: error: 'cout' was not declared in this scope
   25 |     cout << 1<< endl;
      |     ^~~~
a.cc:25:17: error: 'endl' was not declared in this scope
   25 |     cout << 1<< endl;
      |                 ^~~~
Language: C++

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

int main() {
  str s;
  cin >> s;
  cout << (s[0]=='M'?6:(s[0]=='W'?4:(s[0]=='F'?2:(s[2]=='N'?7:(s[2]=='T'?1:(s[2]=='E'?5:3)))))) << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:5:3: error: 'str' was not declared in this scope; did you mean 'std'?
    5 |   str s;
      |   ^~~
      |   std
a.cc:6:10: error: 's' was not declared in this scope
    6 |   cin >> s;
      |          ^
Language: C++

include <iostream>
using namespace std;
int main(){
  string S;
  cin >> S;
  if(S == SUN){
    cout << 7<< endl;
  }
  if(S == MON){
    cout << 6<< endl;
  }
  if(S == TUE){
    cout << 5<< endl;
  }
  if(S == WED){
    cout << 4<< endl;
  }
  if(S == THU){
    cout << 3<< endl;
  }
  if(S == FRY){
    cout << 2<< endl;
  }
  if(S == SAT){
    cout << 1<< endl;
  }
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include <iostream>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:4:3: error: 'string' was not declared in this scope
    4 |   string S;
      |   ^~~~~~
a.cc:5:3: error: 'cin' was not declared in this scope
    5 |   cin >> S;
      |   ^~~
a.cc:5:10: error: 'S' was not declared in this scope
    5 |   cin >> S;
      |          ^
a.cc:6:11: error: 'SUN' was not declared in this scope
    6 |   if(S == SUN){
      |           ^~~
a.cc:7:5: error: 'cout' was not declared in this scope
    7 |     cout << 7<< endl;
      |     ^~~~
a.cc:7:17: error: 'endl' was not declared in this scope
    7 |     cout << 7<< endl;
      |                 ^~~~
a.cc:9:11: error: 'MON' was not declared in this scope
    9 |   if(S == MON){
      |           ^~~
a.cc:10:5: error: 'cout' was not declared in this scope
   10 |     cout << 6<< endl;
      |     ^~~~
a.cc:10:17: error: 'endl' was not declared in this scope
   10 |     cout << 6<< endl;
      |                 ^~~~
a.cc:12:11: error: 'TUE' was not declared in this scope
   12 |   if(S == TUE){
      |           ^~~
a.cc:13:5: error: 'cout' was not declared in this scope
   13 |     cout << 5<< endl;
      |     ^~~~
a.cc:13:17: error: 'endl' was not declared in this scope
   13 |     cout << 5<< endl;
      |                 ^~~~
a.cc:15:11: error: 'WED' was not declared in this scope
   15 |   if(S == WED){
      |           ^~~
a.cc:16:5: error: 'cout' was not declared in this scope
   16 |     cout << 4<< endl;
      |     ^~~~
a.cc:16:17: error: 'endl' was not declared in this scope
   16 |     cout << 4<< endl;
      |                 ^~~~
a.cc:18:11: error: 'THU' was not declared in this scope
   18 |   if(S == THU){
      |           ^~~
a.cc:19:5: error: 'cout' was not declared in this scope
   19 |     cout << 3<< endl;
      |     ^~~~
a.cc:19:17: error: 'endl' was not declared in this scope
   19 |     cout << 3<< endl;
      |                 ^~~~
a.cc:21:11: error: 'FRY' was not declared in this scope
   21 |   if(S == FRY){
      |           ^~~
a.cc:22:5: error: 'cout' was not declared in this scope
   22 |     cout << 2<< endl;
      |     ^~~~
a.cc:22:17: error: 'endl' was not declared in this scope
   22 |     cout << 2<< endl;
      |                 ^~~~
a.cc:24:11: error: 'SAT' was not declared in this scope
   24 |   if(S == SAT){
      |           ^~~
a.cc:25:5: error: 'cout' was not declared in this scope
   25 |     cout << 1<< endl;
      |     ^~~~
a.cc:25:17: error: 'endl' was not declared in this scope
   25 |     cout << 1<< endl;
      |                 ^~~~
Language: C++

s = str(input())
  
if s == 'SAT':
    print('1')
elif s == 'SUN':
    print('7')
elif s == 'MON':
    print('6')
elif s == 'TUE':
    print('5')
elif s == 'WED':
    print('4')
elif s == 'THU':
    print('3')
elif s == 'FR':
    print('2')

Compiler output:
a.cc:3:9: warning: multi-character character constant [-Wmultichar]
    3 | if s == 'SAT':
      |         ^~~~~
a.cc:5:11: warning: multi-character character constant [-Wmultichar]
    5 | elif s == 'SUN':
      |           ^~~~~
a.cc:7:11: warning: multi-character character constant [-Wmultichar]
    7 | elif s == 'MON':
      |           ^~~~~
a.cc:9:11: warning: multi-character character constant [-Wmultichar]
    9 | elif s == 'TUE':
      |           ^~~~~
a.cc:11:11: warning: multi-character character constant [-Wmultichar]
   11 | elif s == 'WED':
      |           ^~~~~
a.cc:13:11: warning: multi-character character constant [-Wmultichar]
   13 | elif s == 'THU':
      |           ^~~~~
a.cc:15:11: warning: multi-character character constant [-Wmultichar]
   15 | elif s == 'FR':
      |           ^~~~
a.cc:1:1: error: 's' does not name a type
    1 | s = str(input())
      | ^
Language: C++

        #include <iostream>
        using namespace std;
         
        int main()
        {
          string N;
          scanf_s("%d",&N,3);
          if(N == "SAT"){
            std::cout << 1 << std::endl;
          }else if(N == "FRI"){
            std::cout << 2 << std::endl;
          }else if(N == "THU"){
            std::cout << 3 << std::endl;
          }else if(N == "WED"){
            std::cout << 4 << std::endl;    
          }else if(N == "TUE"){
            std::cout << 5 << std::endl; 
          }else if(N == "MON"){
            std::cout << 6 << std::endl;  
          }else{
            std::cout << 7 << std::endl; 
          }
        }

Compiler output:
a.cc: In function 'int main()':
a.cc:7:11: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
    7 |           scanf_s("%d",&N,3);
      |           ^~~~~~~
      |           scanf
Language: C++

        #include <iostream>
        using namespace std;
         
        int main()
        {
          string N;
          scanf_s("%d",&N);
          if(N == "SAT"){
            std::cout << 1 << std::endl;
          }else if(N == "FRI"){
            std::cout << 2 << std::endl;
          }else if(N == "THU"){
            std::cout << 3 << std::endl;
          }else if(N == "WED"){
            std::cout << 4 << std::endl;    
          }else if(N == "TUE"){
            std::cout << 5 << std::endl; 
          }else if(N == "MON"){
            std::cout << 6 << std::endl;  
          }else{
            std::cout << 7 << std::endl; 
          }
        }

Compiler output:
a.cc: In function 'int main()':
a.cc:7:11: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
    7 |           scanf_s("%d",&N);
      |           ^~~~~~~
      |           scanf
Language: C++

        #include <iostream>
        using namespace std;
         
        int main()
        {
          String N;
          scanf("%d",%N);
          if(N == "SAT"){
            std::cout << 1 << std::endl;
          }else if(N == "FRI"){
            std::cout << 2 << std::endl;
          }else if(N == "THU"){
            std::cout << 3 << std::endl;
          }else if(N == "WED"){
            std::cout << 4 << std::endl;    
          }else if(N == "TUE"){
            std::cout << 5 << std::endl; 
          }else if(N == "MON"){
            std::cout << 6 << std::endl;  
          }else{
            std::cout << 7 << std::endl; 
          }

Compiler output:
a.cc: In function 'int main()':
a.cc:6:11: error: 'String' was not declared in this scope
    6 |           String N;
      |           ^~~~~~
a.cc:7:22: error: expected primary-expression before '%' token
    7 |           scanf("%d",%N);
      |                      ^
a.cc:7:23: error: 'N' was not declared in this scope
    7 |           scanf("%d",%N);
      |                       ^
a.cc:22:12: error: expected '}' at end of input
   22 |           }
      |            ^
a.cc:5:9: note: to match this '{'
    5 |         {
      |         ^
Language: C++

    #include <iostream>
    using namespace std;
     
    int main()
    {
      String N;
      scanf("%d",N);
      if(N == "SAT"){
        std::cout << 1 << std::endl;
      }else if(N == "FRI"){
        std::cout << 2 << std::endl;
      }else if(N == "THU"){
        std::cout << 3 << std::endl;
      }else if(N == "WED"){
        std::cout << 4 << std::endl;    
      }else if(N == "TUE"){
        std::cout << 5 << std::endl; 
      }else if(N == "MON"){
        std::cout << 6 << std::endl;  
      }else{
        std::cout << 7 << std::endl; 
      }

Compiler output:
a.cc: In function 'int main()':
a.cc:6:7: error: 'String' was not declared in this scope
    6 |       String N;
      |       ^~~~~~
a.cc:7:18: error: 'N' was not declared in this scope
    7 |       scanf("%d",N);
      |                  ^
a.cc:22:8: error: expected '}' at end of input
   22 |       }
      |        ^
a.cc:5:5: note: to match this '{'
    5 |     {
      |     ^
Language: C++

    #include <iostream>
    using namespace std;
     
    int main()
    {
      String N;
      scanf("%d",N);
      if(N == 'SAT'){
        std::cout << 1 << std::endl;
      }else if(N == 'FRI'){
        std::cout << 2 << std::endl;
      }else if(N == 'THU'){
        std::cout << 3 << std::endl;
      }else if(N == 'WED'){
        std::cout << 4 << std::endl;    
      }else if(N == 'TUE'){
        std::cout << 5 << std::endl; 
      }else if(N == 'MON'){
        std::cout << 6 << std::endl;  
      }else{
        std::cout << 7 << std::endl; 
      }

Compiler output:
a.cc:8:15: warning: multi-character character constant [-Wmultichar]
    8 |       if(N == 'SAT'){
      |               ^~~~~
a.cc:10:21: warning: multi-character character constant [-Wmultichar]
   10 |       }else if(N == 'FRI'){
      |                     ^~~~~
a.cc:12:21: warning: multi-character character constant [-Wmultichar]
   12 |       }else if(N == 'THU'){
      |                     ^~~~~
a.cc:14:21: warning: multi-character character constant [-Wmultichar]
   14 |       }else if(N == 'WED'){
      |                     ^~~~~
a.cc:16:21: warning: multi-character character constant [-Wmultichar]
   16 |       }else if(N == 'TUE'){
      |                     ^~~~~
a.cc:18:21: warning: multi-character character constant [-Wmultichar]
   18 |       }else if(N == 'MON'){
      |                     ^~~~~
a.cc: In function 'int main()':
a.cc:6:7: error: 'String' was not declared in this scope
    6 |       String N;
      |       ^~~~~~
a.cc:7:18: error: 'N' was not declared in this scope
    7 |       scanf("%d",N);
      |                  ^
a.cc:22:8: error: expected '}' at end of input
   22 |       }
      |        ^
a.cc:5:5: note: to match this '{'
    5 |     {
      |     ^
Language: C++

#include <iostream>
using namespace std;

int main()
{
  char N[3];
  scanf("%d",N);
  if(N == 'SAT'){
    std::cout << 1 << std::endl;
  }else if(N == 'FRI'){
    std::cout << 2 << std::endl;
  }else if(N == 'THU'){
    std::cout << 3 << std::endl;
  }else if(N == 'WED'){
    std::cout << 4 << std::endl;    
  }else if(N == 'TUE'){
    std::cout << 5 << std::endl; 
  }else if(N == 'MON'){
    std::cout << 6 << std::endl;  
  }else{
    std::cout << 7 << std::endl; 
  }

Compiler output:
a.cc:8:11: warning: multi-character character constant [-Wmultichar]
    8 |   if(N == 'SAT'){
      |           ^~~~~
a.cc:10:17: warning: multi-character character constant [-Wmultichar]
   10 |   }else if(N == 'FRI'){
      |                 ^~~~~
a.cc:12:17: warning: multi-character character constant [-Wmultichar]
   12 |   }else if(N == 'THU'){
      |                 ^~~~~
a.cc:14:17: warning: multi-character character constant [-Wmultichar]
   14 |   }else if(N == 'WED'){
      |                 ^~~~~
a.cc:16:17: warning: multi-character character constant [-Wmultichar]
   16 |   }else if(N == 'TUE'){
      |                 ^~~~~
a.cc:18:17: warning: multi-character character constant [-Wmultichar]
   18 |   }else if(N == 'MON'){
      |                 ^~~~~
a.cc: In function 'int main()':
a.cc:8:8: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    8 |   if(N == 'SAT'){
      |      ~~^~~~~~~~
a.cc:10:14: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |   }else if(N == 'FRI'){
      |            ~~^~~~~~~~
a.cc:12:14: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   12 |   }else if(N == 'THU'){
      |            ~~^~~~~~~~
a.cc:14:14: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   14 |   }else if(N == 'WED'){
      |            ~~^~~~~~~~
a.cc:16:14: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   16 |   }else if(N == 'TUE'){
      |            ~~^~~~~~~~
a.cc:18:14: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   18 |   }else if(N == 'MON'){
      |            ~~^~~~~~~~
a.cc:22:4: error: expected '}' at end of input
   22 |   }
      |    ^
a.cc:5:1: note: to match this '{'
    5 | {
      | ^
Language: C++

a = {"SUN":7,"MON":6,"TUE":5,"WED":4,"THU":3,"FRI":2,"SAT":1}
print(a[input()])

Compiler output:
a.cc:1:1: error: 'a' does not name a type
    1 | a = {"SUN":7,"MON":6,"TUE":5,"WED":4,"THU":3,"FRI":2,"SAT":1}
      | ^
a.cc:2:6: error: expected constructor, destructor, or type conversion before '(' token
    2 | print(a[input()])
      |      ^
Language: C++

#include <iostream>
using namespace std;
int main() {
  string s;
  cin >> s;
  if (s == "SUN"){
cout << 7 << endl;
  } else if (s == "MON"){
cout << 6 << endl;
  } else if (s == "TUE"){
  cout << 5 << endl;
  } else if( s == "WED"){
 cout << 4 << endl;
  } else if (s == "THU"){
 cout << 3 << endl;
    else if ( s == "FRI"){
 cout << 2 << endl;
    } else cout << 1 << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:16:5: error: expected '}' before 'else'
   16 |     else if ( s == "FRI"){
      |     ^~~~
a.cc:14:25: note: to match this '{'
   14 |   } else if (s == "THU"){
      |                         ^
a.cc: At global scope:
a.cc:20:1: error: expected declaration before '}' token
   20 | }
      | ^
Language: C

#include<stdio.h>

int main(void){
  int a,i;
  char S[6]={"SUN","MON","TUE","WED","THU","FRI","SAT"};
  scanf("%s\n", S);
  for(i=0; i < 7; i++){
    if(S == S[i]){
      a = 7-i;
    }
  }
  printf("%d\n", a);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:20: error: excess elements in 'char[6]' initializer
    5 |   char S[6]={"SUN","MON","TUE","WED","THU","FRI","SAT"};
      |                    ^~~~~
main.c:5:20: note: (near initialization for 'S')
main.c:5:26: error: excess elements in 'char[6]' initializer
    5 |   char S[6]={"SUN","MON","TUE","WED","THU","FRI","SAT"};
      |                          ^~~~~
main.c:5:26: note: (near initialization for 'S')
main.c:5:32: error: excess elements in 'char[6]' initializer
    5 |   char S[6]={"SUN","MON","TUE","WED","THU","FRI","SAT"};
      |                                ^~~~~
main.c:5:32: note: (near initialization for 'S')
main.c:5:38: error: excess elements in 'char[6]' initializer
    5 |   char S[6]={"SUN","MON","TUE","WED","THU","FRI","SAT"};
      |                                      ^~~~~
main.c:5:38: note: (near initialization for 'S')
main.c:5:44: error: excess elements in 'char[6]' initializer
    5 |   char S[6]={"SUN","MON","TUE","WED","THU","FRI","SAT"};
      |                                            ^~~~~
main.c:5:44: note: (near initialization for 'S')
main.c:5:50: error: excess elements in 'char[6]' initializer
    5 |   char S[6]={"SUN","MON","TUE","WED","THU","FRI","SAT"};
      |                                                  ^~~~~
main.c:5:50: note: (near initialization for 'S')
main.c:8:10: warning: comparison between pointer and integer
    8 |     if(S == S[i]){
      |          ^~
Language: C

#include<stdio.h>

int main(void){
  int a;
  char S[n]={"SUN","MON","TUE","WED","THU","FRI","SAT"};
  scanf("%s\n", S);
  for(i=0; i < 7; i++){
    if(S == S[i]){
      a = 7-i;
    }
  }
  printf("%d\n", a);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:10: error: 'n' undeclared (first use in this function)
    5 |   char S[n]={"SUN","MON","TUE","WED","THU","FRI","SAT"};
      |          ^
main.c:5:10: note: each undeclared identifier is reported only once for each function it appears in
main.c:7:7: error: 'i' undeclared (first use in this function)
    7 |   for(i=0; i < 7; i++){
      |       ^