#include<iostream>
#include<cstdio>
#include<cmath>
using namespace std;
#define int long long
signed main(){
	int a,b,n;
	while( scanf("%lld %lld %lld", &a, &b, &n) != EOF ){
		int s=0;
		for(int i=1;i<=n;i++){
			s+=(a*(int)pow(10,i)/b)%10;
		}
		cout << s << endl;
	}
	return 0;
}