#include <bits/stdc++.h>
using namespace std;
vector<int> b;
int prim_check(long long n) {
  if (n == 2) return 1;
  if (n % 2 == 0 || n == 1) return 0;
  for (int i = 3; i * i <= n; i += 2)
    if (n % i == 0) {
      return 0;
      break;
    }
  return 1;
}
int main() {
  long long n, d;
  cin >> n;
  if (n == 3 || n == 5 || n == 7) {
    cout << "1" << endl << n;
    return 0;
  }
  d = n - 3;
  for (long long i = 3;; i += 2) {
    if (prim_check(i)) {
      long long j = d - i;
      if (prim_check(j)) {
        cout << "3" << endl << "3 " << i << " " << j;
        break;
      }
    }
  }
  return 0;
}
