#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) {
  while (b) {
    a %= b;
    swap(a, b);
  }
  return a;
}
int sum(int a, int o) {
  int ans = 0;
  while (a) {
    ans += a % o;
    a /= o;
  }
  return ans;
}
int main() {
  int A;
  scanf("%d", &A);
  int ans = 0;
  for (int i = 2; i < A; i++) {
    ans += sum(A, i);
  }
  printf("%d/%d\n", ans / gcd(ans, A - 2), (A - 2) / gcd(ans, A - 2));
  return 0;
}
