#include <iostream>
#include <cstdio>

int main(){
	int a, b, n;
	while(~scanf("%d%d%d", &a, &b, &n)){
		a %= b;//ツ渉ャツ青板閉板づ個づ敖づ可つキツづゥ
		int res = 0;
		for(;n;n--){
			a *= 10;
			res += a / b;
			a %= b;	
		}
		printf("%d\n", res);
	}
	return 0;
}