#include<bits/stdc++.h>
using namespace std;

int x[100010], y[100010];

int main() {
	ios::sync_with_stdio(false);
	int a,b,m; cin >> a >> b >> m;
	for (int i = 1; i <= a; i++) cin >> x[i];
	for (int j = 1; j <= b; j++) cin >> y[j];
	int ans = 10000000;
	while (m--) {
		int p,q,r; cin >> p >> q >> r;
		ans = min(ans, x[p] + y[q] - r);
	}
	sort(x+1,x+a+1);
	sort(y+1,y+b+1);
	cout << min(x[1] + y[1], ans) << "\n";
}