#include <bits/stdc++.h>
using namespace std;
void solution(long long int tc = 0) {
  int n;
  cin >> n;
  cout << n << ' ';
  for (int i = 1; i <= n - 1; i++) cout << i << ' ';
  cout << '\n';
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  unsigned long long tc = 1;
  for (unsigned long long t = 0; t < tc; ++t) solution(t);
  return 0;
}
