import io.StdIn._
object Main extends App {
    val Array(a,b,m) = readLine.split(" ").map(_.toInt)
    val as = readLine.split(" ").map(_.toInt)
    val bs = readLine.split(" ").map(_.toInt)
    val xycs = for (_ <- 1 to m) yield readLine.split(" ").map(_.toInt)

    val prices_saled = for (xyc <- xycs) yield {
        val x = xyc.head
        val y = xyc(1)
        val c = xyc.last
        as(x-1) + bs(y-1) - c // return 値引かれた価格
    }

    val all_prices = prices_saled :+ (as.min + bs.min)
    println(all_prices.min)
}