#include <bits/stdc++.h>
using namespace std;
int solve() {
  int n;
  cin >> n;
  if (n == 1)
    cout << 1 << endl;
  else {
    cout << n << " ";
    for (int i = 1; i <= n - 1; ++i) cout << i << " ";
    cout << "\n";
  }
  return 0;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int t;
  t = 1;
  while (t-- != 0) solve();
  return 0;
}
