#include <bits/stdc++.h>
using namespace std;
const long long int N = 100005;
void solve() {
  long long int m, n;
  cin >> n >> m;
  long long int count = 0;
  for (long long int i = 1; i <= n; i++) {
    count += (m + i % 5) / 5;
  }
  cout << count << endl;
  return;
}
int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  solve();
  return 0;
}
