#include <iostream>

#define rep(i,n) for(int i=0;i<n;i++)

using namespace std;

int main()
{
	double a,b;
	int n;
	while(cin >> a >> b >> n)
	{
		double temp = (a/b) - (int)(a/b);
		int ans = 0;

		rep(i,n)
		{
			temp *= 10;
			ans += (int)temp;
			temp = temp - (int)temp;
		}

		cout << ans << endl;
	}
	return 0;
}