#include <iostream>
#include <cmath>
using namespace std;

int decimal(double n, int digit){
	if (digit == 0) {
		return (int)(10.0*(n - (double)(int)n));
	}else{
		return decimal(10.0*(n - (double)(int)n), digit-1);
	}
}

int main(){
	int a, b, n;
	double tmp;
	int sum;
	while (cin >> a >> b >> n) {
		sum = 0;
		for (int i = 0; i < n; i++) {
			sum += decimal((double)a/(double)b, i);
		}
		cout << sum << endl;
	} 
	return 0;
}