#include <bits/stdc++.h>
using namespace std;
const int N = 5e2 + 10;
int ans, mac, n;
int main() {
  ios_base::sync_with_stdio(false);
  cin >> n;
  while (ans < n) {
    mac += 5;
    int x = mac;
    while (x % 5 == 0) {
      x /= 5;
      ans++;
    }
  }
  if (ans == n) {
    cout << 5 << '\n';
    for (int i = mac; i < mac + 5; ++i) {
      cout << i << ' ';
    }
    cout << '\n';
    return 0;
  }
  cout << 0 << '\n';
  return 0;
}
