#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m;
  long long int count = 0, a[6][3];
  cin >> m >> n;
  for (int i = 1; i <= 5; ++i) a[i][1] = m / 5;
  for (int i = 1; i <= m % 5; ++i) a[i][1]++;
  for (int i = 1; i <= 5; ++i) a[i][2] = n / 5;
  for (int i = 1; i <= n % 5; ++i) a[i][2]++;
  for (int i = 1; i < 5; ++i) count += a[i][1] * a[5 - i][2];
  count += a[5][1] * a[5][2];
  cout << count;
}
