#include <bits/stdc++.h>
using namespace std;
const int maxn = 0x3f3f3f3f;
int main() {
  int n;
  scanf("%d", &n);
  int ou = n / 2;
  int ji = n - ou;
  int sum = ou * 2 + ji;
  printf("%d\n", sum);
  for (int i = 2; i <= n; i += 2) {
    printf("%d ", i);
  }
  for (int i = 1; i <= n; i += 2) {
    printf("%d ", i);
  }
  for (int i = 2; i <= n; i += 2) {
    printf("%d ", i);
  }
}
