#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
using namespace std;
class segtree {
 public:
  long long N = 1048576, inf = 1e17;
  long long add[2097152], now[2097152], l[2097152], r[2097152];
  void build() {
    for (long long i = 0; i < N; i++) l[i + N] = r[i + N] = i + 1;
    for (long long i = N - 1; i >= 1; i--)
      l[i] = l[i << 1], r[i] = r[(i << 1) | 1];
  }
  void push(long long p) {
    if (add[p]) {
      add[p << 1] += add[p];
      now[p << 1] += add[p];
      add[(p << 1) | 1] += add[p];
      now[(p << 1) | 1] += add[p];
      add[p] = 0;
    }
  }
  void up(long long p, long long l1, long long r1, long long x) {
    if (l[p] >= l1 && r1 >= r[p]) {
      now[p] += x;
      add[p] += x;
      return;
    }
    if (l1 > r[p] || l[p] > r1) return;
    push(p);
    up(p << 1, l1, r1, x);
    up((p << 1) | 1, l1, r1, x);
    now[p] = max(now[p << 1], now[(p << 1) | 1]);
  }
  long long get(long long p, long long l1, long long r1) {
    if (l[p] >= l1 && r1 >= r[p]) return now[p];
    if (l1 > r[p] || l[p] > r1) return -inf;
    push(p);
    return max(get(p << 1, l1, r1), get((p << 1) | 1, l1, r1));
  }
} tree;
const long long maxx = 1e6 + 5;
long long a[maxx], b[maxx];
long long n, m, k, maxi = 2e12;
vector<pair<long long, long long>> v[maxx];
signed main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  tree.build();
  long long x, y, z;
  cin >> n >> m >> k;
  for (long long i = 1; i < maxx; i++) a[i] = b[i] = maxi;
  for (long long i = 1; i <= n; i++) {
    cin >> x >> y;
    a[x] = min(a[x], y);
  }
  for (long long i = 1; i <= m; i++) {
    cin >> x >> y;
    b[x] = min(b[x], y);
  }
  for (long long i = 1; i <= k; i++) {
    cin >> x >> y >> z;
    y++;
    x++;
    v[y].emplace_back(make_pair(x, z));
  }
  for (long long i = 1; i < maxx; i++) tree.up(1, i, i, -a[i]);
  long long ans = -maxi, last = tree.get(1, 1, maxx - 1);
  for (long long i = 1; i < maxx; i++) {
    if (!v[i].size()) {
      ans = max(ans, last - b[i]);
      continue;
    }
    for (auto u : v[i]) {
      tree.up(1, u.first, maxx - 1, u.second);
    }
    last = tree.get(1, 1, maxx - 1);
    ans = max(ans, last - b[i]);
  }
  cout << ans << '\n';
  return 0;
}
