#include <bits/stdc++.h>
int a[1005];
int n;
void f(int x) {
  int t;
  if (x < n) {
    f(x + 1);
    t = a[x];
    a[x] = a[x + 1];
    a[x + 1] = t;
  }
}
int main() {
  int i, j;
  scanf("%d", &n);
  for (i = 1; i <= n; i++) a[i] = i;
  f(1);
  printf("%d", a[1]);
  for (i = 2; i <= n; i++) printf(" %d", a[i]);
  printf("\n");
}
