#include <bits/stdc++.h>
using namespace std;
const int N=2e5+5;
int A,B,m,ans,id1,id2,c;
int a[N],b[N]; 
int main(){
	ans=2e9;
	scanf("%d%d%d",&A,&B,&m);
	for (register int i=1; i<=A; ++i) scanf("%d",&a[i]);
	for (register int i=1; i<=B; ++i) scanf("%d",&b[i]);

	for (register int i=1; i<=m; ++i)
	{
		scanf("%d%d%d",&id1,&id2,&c);
		ans=min(ans,a[id1]+b[id2]-c);
	}	
	sort(a+1,a+A+1);
	sort(b+1,b+B+1);
	ans=min(ans,a[1]+b[1]);
	printf("%d\n",ans);
return 0;	
}