#include <bits/stdc++.h>
using namespace std;
int a_1, a_2, a_3, b_1, b_2, b_3, n;
void solve() {
  int l = a_1 + a_2 + a_3 + 4;
  l = l / 5;
  int r = b_1 + b_2 + b_3 + 9;
  r = r / 10;
  if ((l + r) <= n)
    printf("YES\n");
  else
    printf("NO\n");
}
int main() {
  while (scanf("%d%d%d%d%d%d%d", &a_1, &a_2, &a_3, &b_1, &b_2, &b_3, &n) !=
         EOF) {
    solve();
  }
  return 0;
}
