#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int n, m, x, count = 0;
  cin >> n >> m;
  for (int i = 1; i <= n; i++) {
    x = i % 5;
    count += (m + x) / 5;
  }
  cout << count << endl;
  return 0;
}
