#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#include<math.h>
#define BUFSIZE 1000000
int A,B,N;
long long result = 0;
long long rem[BUFSIZE]={0};



int main(void){

  scanf("%d %d %d",&A,&B,&N);
  for(int i = 1;i < N + 1; i++){
    rem[i] = (A*i - (A*i % B))/B - A*(i - i%B)/B;
    if(rem[i] >= rem[i-1])   result = rem[i];
  }

printf("%d",result);

}
