#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int a, b, c, t, i, j, k, l, m, n, o, p;
  cin >> n;
  p = 0;
  for (i = 5;; i = i + 5) {
    o = 1;
    p = 0;
    m = 5;
    while (o == 1) {
      j = i / m;
      p += j;
      m *= 5;
      if (j == 0) break;
    }
    if (p == n) {
      cout << "5\n";
      for (k = i; k < i + 5; k++) cout << k << " ";
      break;
    }
    if (p > n) {
      cout << "0\n";
      break;
    }
  }
}
