#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  int n, i, x;
  vector<int> ans;
  cin >> n;
  int cnt = 0;
  for (i = 1; i < 10 * n; i++) {
    x = i;
    while (x % 5 == 0) {
      x /= 5;
      cnt++;
    }
    if (cnt == n) break;
  }
  if (cnt != n) return cout << "0\n", 0;
  cout << "5\n";
  for (int j = 0; j < 5; j++) cout << i + j << " ";
  cout << "\n";
  return 0;
}
