#include <bits/stdc++.h>
long long gcd(long long a, long long b) { return (!b) ? a : gcd(b, a % b); }
long long lcm(long long a, long long b) { return (((a * b) / gcd(a, b))); }
void out() {
  puts("-1");
  exit(0);
}
using namespace std;
int n;
int main() {
  {
    cin >> n;
    if (n == 2) {
      cout << "2 1\n";
      return 0;
    }
    if (n == 3) {
      cout << "1 3 2\n";
      return 0;
    }
    int p = 0;
    if (n % 2 == 1) {
      cout << "1";
      p = 3;
      for (int i = 1; i <= n / 2; i++) {
        cout << " " << p << " " << p - 1;
        p += 2;
      }
      cout << endl;
    } else {
      cout << "2";
      if (n >= 2) {
        cout << " 1";
        p = 2;
        for (int i = 1; i <= n / 2 - 1; i++) {
          p += 2;
          cout << " " << p << " " << p - 1;
        }
      }
      cout << endl;
    }
  }
  return 0;
}
