#include <bits/stdc++.h>
using namespace std;
long long mod(long long a, long long n) {
  if (n < 0) n *= -1;
  if (a >= 0) return a % n;
  a = (-a) % n;
  if (a < 0) a += n;
  return a;
}
long long gcd(long long a, long long b) {
  if (a < 0) a *= -1;
  if (b < 0) b *= -1;
  if (a < b) return gcd(b, a);
  if (a % b == 0) return b;
  return gcd(b, a % b);
}
pair<long long, long long> sol(long long a, long long b) {
  pair<long long, long long> p1, p2, p3;
  long long m, n, q;
  if (a < b) {
    pair<long long, long long> p = sol(b, a);
    return pair<long long, long long>(p.second, p.first);
  }
  p1 = pair<long long, long long>(1, 0);
  p2 = pair<long long, long long>(0, 1);
  m = a;
  n = b;
  while (n != 1) {
    q = m / n;
    p2.first = p1.first - q * p2.first;
    p2.second = p1.second - q * p2.second;
    p1.first = (p1.first - p2.first) / q;
    p1.second = (p1.second - p2.second) / q;
    n = m % n;
    m = (m - n) / q;
  }
  return p2;
}
long long pro(long long a, long long b, long long c) {
  long long q1, q2, r1, r2;
  r1 = mod(a, c);
  if (a > 0 || r1 == 0)
    q1 = a / c;
  else
    q1 = -(a / c + 1);
  r2 = mod(b, c);
  if (b > 0 || r2 == 0)
    q2 = b / c;
  else
    q2 = -(b / c + 1);
  long long res = q1 + q2;
  if (r1 + r2 >= c) res++;
  return res;
}
int main() {
  long long A, B, C;
  cin >> A >> B >> C;
  if (C == 0)
    cout << "0 0\n";
  else if (A == 0) {
    if (mod(C, B) == 0)
      cout << "0 " << -C / B << endl;
    else
      cout << "-1\n";
  } else if (B == 0) {
    if (mod(C, A) == 0)
      cout << -C / A << " 0\n";
    else
      cout << "-1\n";
  } else {
    if (A < 0) {
      A *= -1;
      B *= -1;
      C *= -1;
    }
    long long D = gcd(A, B);
    if (mod(C, D) != 0)
      cout << "-1\n";
    else {
      A /= D;
      B /= D;
      C /= D;
      long long l1, r1, l2, r2;
      pair<long long, long long> p;
      if (B > 0) {
        p = sol(A, B);
        p.first *= -C;
        p.second *= -C;
      } else {
        p = sol(A, -B);
        p.second *= -1;
        p.first *= -C;
        p.second *= -C;
      }
      cout << p.first << " " << p.second << endl;
    }
  }
  return 0;
}

### Prompt

Develop a solution in cpp to the problem described below:

A line on the plane is described by an equation Ax + By + C = 0. You are to find any point on this line, whose coordinates are integer numbers from  - 5·1018 to 5·1018 inclusive, or to find out that such points do not exist.

Input

The first line contains three integers A, B and C ( - 2·109 ≤ A, B, C ≤ 2·109) — corresponding coefficients of the line equation. It is guaranteed that A2 + B2 > 0.

Output

If the required point exists, output its coordinates, otherwise output -1.

Examples

Input

2 5 3


Output

6 -3

### Response

```cpp
#include <bits/stdc++.h>
using namespace std;
long long mod(long long a, long long n) {
  if (n < 0) n *= -1;
  if (a >= 0) return a % n;
  a = (-a) % n;
  if (a < 0) a += n;
  return a;
}
long long gcd(long long a, long long b) {
  if (a < 0) a *= -1;
  if (b < 0) b *= -1;
  if (a < b) return gcd(b, a);
  if (a % b == 0) return b;
  return gcd(b, a % b);
}
pair<long long, long long> sol(long long a, long long b) {
  pair<long long, long long> p1, p2, p3;
  long long m, n, q;
  if (a < b) {
    pair<long long, long long> p = sol(b, a);
    return pair<long long, long long>(p.second, p.first);
  }
  p1 = pair<long long, long long>(1, 0);
  p2 = pair<long long, long long>(0, 1);
  m = a;
  n = b;
  while (n != 1) {
    q = m / n;
    p2.first = p1.first - q * p2.first;
    p2.second = p1.second - q * p2.second;
    p1.first = (p1.first - p2.first) / q;
    p1.second = (p1.second - p2.second) / q;
    n = m % n;
    m = (m - n) / q;
  }
  return p2;
}
long long pro(long long a, long long b, long long c) {
  long long q1, q2, r1, r2;
  r1 = mod(a, c);
  if (a > 0 || r1 == 0)
    q1 = a / c;
  else
    q1 = -(a / c + 1);
  r2 = mod(b, c);
  if (b > 0 || r2 == 0)
    q2 = b / c;
  else
    q2 = -(b / c + 1);
  long long res = q1 + q2;
  if (r1 + r2 >= c) res++;
  return res;
}
int main() {
  long long A, B, C;
  cin >> A >> B >> C;
  if (C == 0)
    cout << "0 0\n";
  else if (A == 0) {
    if (mod(C, B) == 0)
      cout << "0 " << -C / B << endl;
    else
      cout << "-1\n";
  } else if (B == 0) {
    if (mod(C, A) == 0)
      cout << -C / A << " 0\n";
    else
      cout << "-1\n";
  } else {
    if (A < 0) {
      A *= -1;
      B *= -1;
      C *= -1;
    }
    long long D = gcd(A, B);
    if (mod(C, D) != 0)
      cout << "-1\n";
    else {
      A /= D;
      B /= D;
      C /= D;
      long long l1, r1, l2, r2;
      pair<long long, long long> p;
      if (B > 0) {
        p = sol(A, B);
        p.first *= -C;
        p.second *= -C;
      } else {
        p = sol(A, -B);
        p.second *= -1;
        p.first *= -C;
        p.second *= -C;
      }
      cout << p.first << " " << p.second << endl;
    }
  }
  return 0;
}

```