solve :: Int -> Int -> Int -> Int
solve a b n = floor $ point * fromIntegral a
  where x | n < b-1 = n
          | otherwise = b - 1
        y = (fromIntegral x) / (fromIntegral b)
        point = y - (fromIntegral . floor $ y)

main :: IO ()
main = do
  [a, b, n] <- map (read :: String -> Int) .words <$> getLine
  print $ solve a b n
