#include<stdio.h>
#include<math.h>
int main(){

    long int A,B,N;

    scanf("%ld %ld %ld", &A, &B, &N);

    long long int i;
    int a,b,y;
    int ans=0;

    for( i = 1; i <= N; i++ ){
        a = A*i/B ;
        //a = floor(A * i / B);
        b = i/B;
        //b = floor(i / B);
        y = a - (A * b);
        //printf("x=%d y=%d a=%d b=%d\n", i, y, a, b);
        if( y > ans ) ans = y;
    }

    printf("%d\n", ans);

    return 0;
}
