#include <iostream>

using namespace std;

void solve()
{
	int a, b, n;
	while(cin >> a >> b >> n)
	{
		int k = a % b;
		int ans = 0;
		for(int i = 0; i < n; ++i)
		{
			k *= 10;
			ans += k / b;
			k %= b;
		}
		cout << ans << endl;
	}
}

int main()
{
	solve();
	return(0);
}