#include<iostream>
using namespace std;

int main()
{
    double a, b;
    int sum = 0, n;

    while( cin >> a >> b >> n )
    {
        double c = a / b;

        for( int i = 0; i < n; i++ )
        {
            if( c > 1 )
                c -= (int)c;
            c *= 10;
            sum += (int)c;
        }
        cout << sum << endl;
        sum = 0;
    }

    return 0;
}
