#include <bits/stdc++.h>
using namespace std;
long long int check(long long int a) {
  if (a >= 1000000000 + 7) a %= 1000000000 + 7;
  return a;
}
long long int check2(long long int a) {
  if (a > 0) return a;
  long long int b = a / 1000000000 + 7;
  a -= b * 1000000000 + 7;
  if (a < 0) a += 1000000000 + 7;
  return a;
}
long long int exp(long long int a, long long int n) {
  if (n == 0) return 1;
  if (n == 1) return check(a);
  long long int b = exp(a, n / 2);
  if (n % 2 == 0) return check(b * b);
  return check(b * check(b * a));
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int n;
  cin >> n;
  vector<int> ans;
  int coun = 0;
  for (int i = 2; i <= n; i += 2) {
    coun++;
    ans.push_back(i);
  }
  for (int i = 1; i <= n; i += 2) {
    coun++;
    ans.push_back(i);
  }
  for (int i = 2; i <= n; i += 2) {
    coun++;
    ans.push_back(i);
  }
  cout << coun << endl;
  for (auto itr : ans) cout << itr << " ";
  return 0;
}
