#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c;
  cin >> a >> b >> c;
  int cnt = 0;
  bool found = false;
  int r = a % b;
  while (cnt < b + 1) {
    cnt++;
    a = r * 10;
    int el = a / b;
    if (el == c) {
      found = true;
      break;
    }
    r = a % b;
  }
  if (found)
    cout << cnt;
  else
    cout << -1;
  return 0;
}
