#include <bits/stdc++.h>
using namespace std;
vector<long long> ans;
int main(void) {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  long long n;
  cin >> n;
  if (n == 1)
    cout << "3\n2 1 2";
  else {
    long long m = n + n / 2;
    cout << m << "\n";
    for (long long i = 2; i <= n; i += 2) cout << i << " ";
    for (long long i = 1; i <= n; i += 2) cout << i << " ";
    for (long long i = 2; i <= n; i += 2) cout << i << " ";
  }
  return 0;
}
