#include <bits/stdc++.h>
#pragma comment(linker, "/STACK:136777216")
using namespace std;
int bits(int x) { return x == 0 ? 0 : 1 + bits(x & (x - 1)); }
const double PI = acos(-1.0);
const double eps = 1e-9;
const int INF = 1000000000;
string nextString() {
  char buf[1000000];
  scanf("%s", buf);
  return buf;
}
int dx[] = {0, 1, 0, -1};
int dy[] = {1, 0, -1, 0};
int gcd(int a, int b) { return b == 0 ? a : gcd(b, a % b); }
int main() {
  int n;
  scanf("%d\n", &n);
  for (int i = 1, j = 2; i < n; i++, j++) printf("%d ", j);
  printf("1\n");
  return 0;
}
