#include <iostream>

using namespace std;

int f(long long int a,long long int b,int num){
	long long int tmpC;
	int ans = 0;
	for(int i=1;i<=num;i++){
		tmpC = 1;
		for(int j=0;j<i;j++){
			tmpC *= 10;		
		}
		ans += (int)(((tmpC*a)/b)%10);
	}

	return ans;
}

int main(){
	long long int a,b;
	int n;
	double c;
	while(cin>>a){
		cin>>b;
		cin>>n;
		c = a/(double)b;
		cout<<f(a,b,n)<<endl;
	}

	return 0;
}

/*
Sample Input
1 2 3
2 3 4
5 4 3
4 3 2
Output for the Sample Input
5
24
7
6
*/