#include <stdio.h>
#include <math.h>

int main(){
	int a,b,n,ans,i,j;
	double ab;
	while(scanf("%d %d %d",&a,&b,&n) != EOF){
		ans = 0;
		for(i = 1;i <= n;i++){
			ans += (int)((long long int)((double)a / (double)b * pow(10.0,(double)i)) % 10);
		}
		printf("%d\n",ans);
	}
	return 0;
}