#include <bits/stdc++.h>
using namespace std;
long long n;
int main() {
  while (scanf("%lld", &n) != EOF) {
    if (n == 1 || n == 2)
      printf("-1\n");
    else if (n % 2)
      printf("%lld %lld\n", (n * n - 1) / 2, (n * n + 1) / 2);
    else
      printf("%lld %lld\n", n * n / 4 - 1, n * n / 4 + 1);
  }
  return 0;
}
