#include <iostream>
#include <cstdio>
#define N 100005
using namespace std;

int n, m, k, mn, x, y, c, mna = 1e9, mnb = 1e9, a[N], b[N];
int main()
{
	int i;
	cin >> n >> m >> k;
	for (i = 1; i <= n; i++) scanf("%d", &a[i]), mna = min(mna, a[i]);
	for (i = 1; i <= m; i++) scanf("%d", &b[i]), mnb = min(mnb, b[i]);
	mn = mna + mnb;
	while (k--) {
		scanf("%d %d %d", &x, &y, &c);
		mn = min(mn, a[x] + b[y] - c);
	}
    cout << mn << endl;
    return 0;
}