#include <bits/stdc++.h>
using namespace std;
vector<int> e[200010];
int n, a[200010], L[200010], R[200010], dfn[200010], dfs_clock;
void dfs(int rt, int fa) {
  L[rt] = ++dfs_clock;
  dfn[dfs_clock] = rt;
  for (int i = 0; i < e[rt].size(); i++) {
    int nxt = e[rt][i];
    if (nxt == fa) continue;
    dfs(nxt, rt);
  }
  R[rt] = dfs_clock;
}
int sum0[200010 << 2], sum1[200010 << 2], f[200010 << 2];
inline void pushup(int rt) {
  sum0[rt] = sum0[rt << 1] + sum0[rt << 1 | 1];
  sum1[rt] = sum1[rt << 1] + sum1[rt << 1 | 1];
}
inline void pushdown(int rt) {
  if (f[rt]) {
    f[rt << 1] ^= 1;
    f[rt << 1 | 1] ^= 1;
    swap(sum0[rt << 1], sum1[rt << 1]);
    swap(sum0[rt << 1 | 1], sum1[rt << 1 | 1]);
    f[rt] = 0;
  }
}
void build(int l, int r, int rt) {
  f[rt] = 0;
  if (l == r) {
    if (a[dfn[l]])
      sum0[rt] = 0, sum1[rt] = 1;
    else
      sum0[rt] = 1, sum1[rt] = 0;
    return;
  }
  int m = (l + r) >> 1;
  build(l, m, rt << 1);
  build(m + 1, r, rt << 1 | 1);
  pushup(rt);
}
void update(int L, int R, int l, int r, int rt) {
  if (L <= l && r <= R) {
    swap(sum0[rt], sum1[rt]);
    f[rt] ^= 1;
    return;
  }
  int m = (l + r) >> 1;
  pushdown(rt);
  if (L <= m) update(L, R, l, m, rt << 1);
  if (R > m) update(L, R, m + 1, r, rt << 1 | 1);
  pushup(rt);
}
int query(int ql, int qr, int l, int r, int rt) {
  if (ql <= l && r <= qr) return sum1[rt];
  int m = (l + r) >> 1;
  int res = 0;
  pushdown(rt);
  if (ql <= m) res += query(ql, qr, l, m, rt << 1);
  if (qr > m) res += query(ql, qr, m + 1, r, rt << 1 | 1);
  pushup(rt);
  return res;
}
char op[15];
int main() {
  scanf("%d", &n);
  int ans = n + n / 2;
  cout << ans << endl;
  for (int i = 1; i <= n; i++) {
    if (i % 2 == 0) cout << i << " ";
  }
  for (int i = 1; i <= n; i++) {
    if (i % 2 == 1) cout << i << " ";
  }
  for (int i = 1; i <= n; i++) {
    if (i % 2 == 0) cout << i << " ";
  }
}
