Go: package main

import "fmt"

func main() {
	week := []string{"sun", "mon", "tue", "wed", "thu", "fri", "sat"}

	var day int
	fmt.Scan(&day)
	fmt.Println(week[(day+4)%7])//土曜日が9日という基準に揃えるために+4
}

C++: #include <iostream>
using namespace std;

int main() {
	int X;
	cin>>X;
	if(X<9){
		X=9-X;
		if(X<0){
			X=X*-1;
		}
		for(int i=0;i<10;i++){
			if(X<8){
				break;
			}
			X=X-7;
		}
		switch(X){
		case 0:cout<<"sat"<<endl;
			break;
		case 1:cout<<"fri"<<endl;
			break;
		case 2:cout<<"thu"<<endl;
			break;
		case 3:cout<<"wed"<<endl;
			break;
		case 4:cout<<"tue"<<endl;
			break;
		case 5:cout<<"mon"<<endl;
			break;
		case 6:cout<<"sun"<<endl;
			break;
		case 7:cout<<"sat"<<endl;
			break;
		}
	}
	else{
		X=9-X;
		if(X<0){
			X=X*-1;
		}
		for(int i=0;i<10;i++){
			if(X<8){
				break;
			}
			X=X-7;
		}
		switch(X){
		case 0:cout<<"sat"<<endl;
			break;
		case 1:cout<<"sun"<<endl;
			break;
		case 2:cout<<"mon"<<endl;
			break;
		case 3:cout<<"tue"<<endl;
			break;
		case 4:cout<<"wed"<<endl;
			break;
		case 5:cout<<"thu"<<endl;
			break;
		case 6:cout<<"fri"<<endl;
			break;
		case 7:cout<<"sat"<<endl;
			break;
		}
	}
	return 0;
}

C++: 
#include<cstdio>
#include<iostream>
#include<algorithm>
#include<string>
#include<cstring>
#include<queue>
#include<vector>
#include<functional>
#include<cmath>
#include<map>
#include<stack>
#include<set>
#include<numeric>
#include<limits>
#include<iomanip>
#include<iterator>

#define all(x) (x).begin(),(x).end()
#define rall(x) (x).rbegin(),(x).rend()
#define rep(i,n) for(int i=0; i<n; i++)
#define FOR(i,a,n) for(int i=a; i<n; i++)

using namespace std;
typedef long long ll;
typedef pair<int, int> pi;
typedef pair<ll, ll> pl;
typedef pair<ll, char> plc;

string mon[] = { "thu","fri","sat","sun","mon","tue","wed"};

int main()
{
	int x;
	cin >> x;
	cout << mon[x % 7] << endl;
	return 0;
}

C++: #include <bits/stdc++.h>
#define rep(i, a, b) for (int i = (a); i < (b); i++)
#define pb push_back
#define all(v) v.begin(),v.end()
#define sort_1(v) sort(v.begin(),v.end())
#define sort_2(v) sort(v.begin(),v.end(),greater<ll>())
#define reverse(v) reverse(v.begin(),v.end())
typedef long long ll;
typedef long double la;
using namespace std;

int main(){
    int x;
    cin >> x;
    int ans = x%7;

    switch(ans){
        case 0:
            cout << "thu" << endl;
            break;
        case 1:
            cout << "fri" << endl;
            break;
        case 2:
            cout << "sat" << endl;
            break;
        case 3:
            cout << "sun" << endl;
            break;
        case 4:
            cout << "mon" << endl;
            break;
        case 5:
            cout << "tue" << endl;
            break;
        case 6:
            cout << "wed" << endl;
            break;
        default:
            break;
    }
}

C++: #include <iostream>
using namespace std;

int main()
{
	int x;
	char day[7][4] = {"sun", "mon", "tue", "wed", "thu", "fri", "sat"};

	cin >> x;
	cout << day[(x + 4) % 7] << endl;
	
	return 0;
}

C++: #include<iostream>
using namespace std;

int main(){
  int d;
  cin >> d;
  if(d%7==0){
    cout << "thu" << endl;
  }
  if(d%7==1){
    cout << "fri" << endl;
  }
  if(d%7==2){
    cout << "sat" << endl;
  }
  if(d%7==3){
    cout << "sun" << endl;
  }
  if(d%7==4){
    cout << "man" << endl;
  }
  if(d%7==5){
    cout << "tue" << endl;
  }
  if(d%7==6){
    cout << "wed" << endl;
  }
  return 0;
}

C++: 
#include<set>
using namespace std;
#include<iostream>
int	main(){
	/*
	while(true){
	
	int A,B,C,D,E,F,G,H,I,J,answer;
		
	cin >> A;
	if(A == 0) return 0;
	cin >> B >> C >> D >> E >> F >> G >> H >> I >> J;
	answer = A - B - C - D-E-F-G-H-I-J;
	cout << answer << endl;

	}
	*/
	/*
	int A,B,C,D,E,F;

	cin >> A, B, C, D;
	if(A < B, C, D){ 
		cout << B + C + D << endl;
	}
	
	else if(B < A, C, D){
		cout << A + C + D << endl;
	}

	else if(C < A && C < B && C < D){
		cout << A + B + D << endl;
	}

	else if(D < A && D < B && D < C){
		cout << A + B + C << endl;
	}

	if(E < F){
		cout << F << endl;
	}

	else{
		cout << E << endl;
	}
	
	return 0;
}*/
	/*
	int N, M;
	cin >> N >> M;
	cout << N + M << endl << N - M << endl << N * M << endl << N / M << endl;
}*/

/*int N, M; 
	cin >> N >> M;
	cout << N % M << endl;
}*/

/*	int N;
	cin >> N;
	cout << -(N % 2)+1 ;
}*/

	/*int A, B, C, D, E ;
	cin >> A >> B >> C >> D >> E;
	cout << (A + B + C + D + E) / 5 ;
}*/

	/*int A, B, C, D ;
	cin >> A >> B >> C >> D;
	cout << (A + B + C + D) / 60 << endl << (A + B + C + D) % 60 << endl;
	*/

/*	int A,B;
	cin >> A >> B;
	cout << ( A + B ) / 2 << endl;*/

/*	int m, f, b;
	cin >> m >> f >> b;

	if ( m + f >= b && m <= b ){
		cout << b - m << endl;
	}
	
	if ( m + f > b && m > b ){
		cout << 0 << endl;
	}


	if ( m + f < b ){
		cout << "NA" << endl;
	}*/

	int X , x ;
	cin >> X ;

	x = X % 7 ;

	if ( x == 2 ){
		cout << "sat" << endl;
	}

	if ( x == 3 ){
		cout << "sun" << endl;
	}

	if ( x == 4 ){
		cout << "mon" << endl;
	}

	if ( x == 5 ){
		cout << "tue" << endl;
	}

	if ( x == 6 ){
		cout << "wed" << endl;
	}

	if ( x == 0 ){
		cout << "thu" << endl;
	}

	if ( x == 1 ){
		cout << "fri" << endl;
	}
}

C++: #include <iostream>
using namespace std;
int main(void){
    int a;
    cin>>a;
    if(a%7==1){cout<<"fri"<<endl;}
    if(a%7==2){cout<<"sat"<<endl;}
    if(a%7==3){cout<<"sun"<<endl;}
    if(a%7==4){cout<<"mon"<<endl;}
    if(a%7==5){cout<<"tue"<<endl;}
    if(a%7==6){cout<<"wed"<<endl;}
    if(a%7==0){cout<<"thu"<<endl;}
}

C++: #include <iostream>
using namespace std;
int main(void){
    int X;
    cin >> X;
    
    if(X%7 == 0) cout << "thu" << endl;
    else if(X%7 == 1) cout << "fri" << endl;
    else if(X%7 == 2) cout << "sat" << endl;
    else if(X%7 == 3) cout << "sun" << endl;
    else if(X%7 == 4) cout << "mon" << endl;
    else if(X%7 == 5) cout << "tue" << endl;
    else if(X%7 == 6) cout << "wed" << endl;
    
    return 0;
    
}

C++: #include <iostream>
using namespace std;
int main(void){
    string week[7] = {"fri", "sat", "sun", "mon", "tue", "wed", "thu"};
    int day;
    cin >> day;
    cout << week[(day - 1) % 7] << endl;
    
}

C++: #include <iostream>
using namespace std;
int main(void){
    int x;
    cin>>x;
    if(x%7==2){
        cout<<"sat"<<endl;
    }
    else if(x%7==3){
        cout<<"sun"<<endl;
    }
    else if(x%7==4){
        cout<<"mon"<<endl;
    }
    else if(x%7==5){
        cout<<"tue"<<endl;
    }
    else if(x%7==6){
        cout<<"wed"<<endl;
    }
    else if(x%7==0){
        cout<<"thu"<<endl;
    }
    else if(x%7==1){
        cout<<"fri"<<endl;
    }
    }

C++: #include <iostream>
using namespace std;
int main(void){
    int x;
    char day[7][5]={"thu","fri","sat","sun","mon","tue","wed"};
    cin>>x;
    cout<<day[x%7]<<endl;
}

C++: #include "bits/stdc++.h"

using namespace std;

int main()
{
   string w[7]={"thu", "fri", "sat", "sun" ,"mon","tue", "wed"};
   int x;
   cin >>x;
   int n=x%7;
   cout << w[n]<< endl;
    return 0;
}

C++: #include<iostream>
using namespace std;
 
int main(){
  string D[] = {"thu", "fri", "sat", "sun", "mon", "tue", "wed"};
  int x;
  cin >> x;
  cout << D[x%7] << endl;
}