#include <iostream>

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

using namespace std;

int main()
{
	int a,b,n;
	while(cin >> a >> b >> n)
	{
		int ans = 0;
		a %= b;

		rep(i,n)
		{
			a *= 10;
			ans += (a/b);
			a %= b;
		}

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