object Main extends App {                                                                                                                                       val sc = new java.util.Scanner (System.in)
  val a,b,m = sc.nextInt
  val alist = List.fill(a)(sc.nextInt)
  val blist = List.fill(b)(sc.nextInt)
  val mlist = List.fill(m)(List.fill(3)(sc.nextInt))
  var min = (for(i <- 0 to m-1) yield(alist(mlist(i)(0)-1) + blist(mlist(i)(1)-1) - mlist(i)(2) )).foldLeft(Int.MaxValue)((min,x)=>if( x < min ) x else min ) 
  for(i <- 0 to a-1){
    for(j <- 0 to b-1){
        if( alist(i) + blist(j)< min) min = alist(i) + blist(j)
    }
  }
  println(min)
}