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

int32_t main() {

    int n; cin >> n;
    vector<vector<int>> dp(n + 1, vector<int> (13, 0));
    
    dp[0][0] = 1;
    for(int j = 1; j <= n; j ++) {
        for(int i = 1; i <= 12; i ++) {

            if(i > j)
                continue;
            else if(i == j)
                dp[i][j] = 1;
            else {
                
                for(int k = 1; k <= j; k ++)
                    dp[j][i] += dp[j - k][i - 1];
            }
        }
    }

    // for(int i = 1; i <= n; i ++) {
    //     for(int j = 1; j <= 12; j ++)
    //         cout << dp[i][j] << ' ';
    //     cout << endl;
    // }

    cout << dp[n][12] << endl;
}
#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define ull unsigned long long
#define uint unsigned int
#define pb push_back
#define str string
#define mp make_pair
#define fi first
#define se second
#define sz(a) (int)(a.size())
#define REP(i, n) for(int i = 0; i < (int)n; ++i) 
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend()
const ll MOD = 1e9 + 7;
const ll INF = 1e18;
const double PI = acos(-1.0);
const int MAXN = (int)3e5 + 7;

void solve(){
    str s; cin >> s;
    cout << s.substr(1) << s[0];
}
 
int main(){
    //freopen("input.txt", "r", stdin);
    //freopen("output.txt", "w", stdout);
    ios_base::sync_with_stdio(false);
    cin.tie(nullptr); cout.tie(nullptr);
    solve();
    return 0;
}