#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, side1, side2;
  cin >> n;
  if (n % 2) {
    side1 = ((n * n) - 1) / 2;
    side2 = ((n * n) + 1) / 2;
  } else {
    side1 = ((n / 2) * (n / 2)) - 1;
    side2 = ((n / 2) * (n / 2)) + 1;
  }
  if (!side1 || !side2 || side1 == side2)
    cout << -1;
  else
    cout << side1 << " " << side2;
  return 0;
}
