#include <cstdio>

int main(void)
{
	int a, b, n;
	
	while (scanf("%d %d %d", &a, &b, &n) != EOF){
		while (a > b){
			a -= b;
		}
		if (a % b == 0){
			puts("0");
			continue;
		}
		int sum = 0, c, d;
		for (int i = 0; i < n; i++){
			c = (a * 10) / b;
			d = (a * 10) % b;
			a = d;
//			printf("%d %d\n", c, sum);
			sum += c;
		}
		printf("%d\n", sum);
	}
	
	return (0);
}