import scala.collection.immutable._
import scala.io.StdIn._
import scala.collection.mutable.Set
object Main {
	def main(args: Array[String]): Unit = {
	  var temp = readLine.split(" ").map(_.toDouble)
	  var nor:Double = temp(0) / temp(1)
	  var sum = new Array[Double](temp(2).toInt);
	  for(i <- 0 until temp(2).toInt){
	    sum(i) = (((nor - Math.floor(nor)).toString + "00000000").charAt(i + 2) - '0').toDouble
	  }
	  println(sum.sum.toInt)
	}
}