#include<bits/stdc++.h>
using namespace std;
const int M=1000000007;
const int N=1000005;
int i,n,a[N],b[N],c,x,y,m,p,f,g,ans;
int main()
{
	scanf("%d %d %d",&n,&m,&p);
	ans=f=g=1<<30;
	for(i=1;i<=n;++i)
	{
		scanf("%d",&a[i]);
		f=min(f,a[i]);
	}
	for(i=1;i<=m;++i)
	{
		scanf("%d",&b[i]);
		g=min(g,b[i]);
	}
	ans=f+g;
	while(p--)
	{
		scanf("%d %d %d",&x,&y,&c);
		ans=min(ans,a[x]+b[y]-c);
	}
	cout<<ans;
}