#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int x, y;
  long long int ydiv[6];
  cin >> x >> y;
  for (int i = 1; i < 6; ++i) ydiv[i] = y / 5;
  int _1div = x / 5;
  int _2div = x / 5;
  int _3div = x / 5;
  int _4div = x / 5;
  int _5div = x / 5;
  if (x % 5 == 1)
    _1div++;
  else if (x % 5 == 2) {
    _1div++;
    _2div++;
  } else if (x % 5 == 3) {
    _1div++;
    _2div++;
    _3div++;
  } else if (x % 5 == 4) {
    _1div++;
    _2div++;
    _3div++;
    _4div++;
  }
  if (y % 5 == 1)
    ydiv[1]++;
  else if (y % 5 == 2) {
    ydiv[1]++;
    ydiv[2]++;
  } else if (y % 5 == 3) {
    ydiv[1]++;
    ydiv[2]++;
    ydiv[3]++;
  } else if (y % 5 == 4) {
    ydiv[1]++;
    ydiv[2]++;
    ydiv[3]++;
    ydiv[4]++;
  }
  long long int count = (_1div * ydiv[4]) + _2div * ydiv[3] + _3div * ydiv[2] +
                        _4div * ydiv[1] + _5div * ydiv[5];
  cout << count << endl;
}
