#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  if (n % 2 == 0) {
    for (int i = 1; i < n; i += 2) {
      cout << i + 1 << " " << i;
      if (i != (n - 1)) cout << " ";
    }
  } else {
    cout << 1;
    for (int i = 2; i < n; i += 2) {
      cout << " " << i + 1 << " " << i;
    }
  }
  cout << "\n";
  return 0;
}
