#include<iostream>
#include<math.h>

using namespace std;

int main(void)
{
	while(1)
	{
		double a,b,c;
		int n;
		if(!(cin>>a>>b>>n))break;
		c=a/b;
		int ans=0;
		for(int i=1;i<=n;i++)
		{
			ans+=(int)(c*pow(10.0,i))%10;
		}
		cout<<ans<<endl;
	}
}