#include <bits/stdc++.h>
using namespace std;
long long b, c;
int n;
int main() {
  scanf("%d", &n);
  if (n < 3) {
    puts("-1");
    return 0;
  }
  if (n & 1) {
    b = ((long long)n * n - 1) / 2;
    c = b + 1;
  } else {
    b = ((long long)n * n - 4) / 4;
    c = b + 2;
  }
  printf("%I64d %I64d\n", b, c);
}
