#include <bits/stdc++.h>
using namespace std;
signed main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  long long T = 1;
  while (T--) {
    long long n;
    cin >> n;
    cout << n << ' ';
    for (long long i = 1; i < n; i++) cout << i << ' ';
    cout << '\n';
  }
  return 0;
}
