#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m;
  scanf("%d %d", &n, &m);
  if (m < n) {
    int t = n;
    n = m;
    m = t;
  }
  long long unsigned count = 0;
  for (int i = 0; i < n; i++) {
    count += (m + ((i + 1 % 5) + 5) % 5) / 5;
  }
  cout << count << endl;
  return 0;
}
