#include <stdio.h>

int dec[20000];

int main(){
	int a,b,n;
	int dummy;
	int sum;
	while(scanf("%d %d %d", &a, &b, &n) != EOF){
		dec[0] = a / b;
		dummy = a % b;

		for(int i = 1; i <= n; i++){
			a = dummy * 10;
			dec[i] = a / b;
			dummy = a % b;
		}
		sum = 0;
		for(int i = 1; i <= n; i++){
			sum += dec[i];
		}
		printf("%d\n",sum);

	}
	return 0;
}