#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
const int SZ = 1e6 + 20;
int n, m, p;
int atk[SZ], def[SZ];
long long tree[SZ << 2], lazy[SZ << 2];
int maxatk, maxdef;
struct zt {
  int d, a, c;
} node[SZ];
bool cmp(zt a, zt b) {
  if (a.d != b.d)
    return a.d < b.d;
  else
    return a.a < b.a;
}
inline void build_tree(int pos, int left, int right) {
  if (left == right) {
    tree[pos] = -def[left];
    return;
  }
  int mid = (left + right) >> 1;
  build_tree(pos << 1, left, mid);
  build_tree(pos << 1 | 1, mid + 1, right);
  tree[pos] = max(tree[pos << 1], tree[pos << 1 | 1]);
}
inline void update_tree(int pos, int left, int right, int val, int start,
                        int end) {
  if (start <= left && right <= end) {
    tree[pos] += val;
    lazy[pos] += val;
    return;
  }
  if (lazy[pos] && left < right) {
    lazy[pos << 1] += lazy[pos], lazy[pos << 1 | 1] += lazy[pos];
    tree[pos << 1] += lazy[pos], tree[pos << 1 | 1] += lazy[pos];
    lazy[pos] = 0;
  }
  int mid = (left + right) >> 1;
  if (start <= mid) update_tree(pos << 1, left, mid, val, start, end);
  if (end > mid) update_tree(pos << 1 | 1, mid + 1, right, val, start, end);
  tree[pos] = max(tree[pos << 1 | 1], tree[pos << 1]);
}
int main() {
  int x, y, c;
  memset(atk, 63, sizeof(atk));
  memset(def, 63, sizeof(def));
  scanf("%d%d%d", &n, &m, &p);
  for (int i = 1; i <= n; i++) {
    scanf("%d%d", &x, &c);
    atk[x] = min(atk[x], c);
    maxatk = max(maxatk, x);
  }
  for (int i = maxatk - 1; i >= 1; i--) atk[i] = min(atk[i + 1], atk[i]);
  for (int i = 1; i <= m; i++) {
    scanf("%d%d", &x, &c);
    def[x] = min(def[x], c);
    maxdef = max(maxdef, x);
  }
  for (int i = maxdef - 1; i >= 1; i--) def[i] = min(def[i], def[i + 1]);
  build_tree(1, 1, maxdef);
  for (int i = 1; i <= p; i++) {
    scanf("%d%d%d", &x, &y, &c);
    node[i] = {x, y, c};
  }
  sort(node + 1, node + p + 1, cmp);
  long long ans = -atk[1] - def[1];
  for (int i = 1; i <= p; i++) {
    if (node[i].a < maxdef)
      update_tree(1, 1, maxdef, node[i].c, node[i].a + 1, maxdef);
    if (node[i].d < maxatk) ans = max(ans, tree[1] - atk[node[i].d + 1]);
  }
  printf("%d", ans);
  return 0;
}
