#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) {
  int t;
  while (b != 0) {
    t = a % b;
    a = b;
    b = t;
  }
  return a;
}
int digit(int n, int i) {
  int a = 0;
  while (n > 0) {
    a += n % i;
    n = n / i;
  }
  return a;
}
int main() {
  int n, x;
  scanf("%d", &n);
  int f = 0;
  for (int i = 2; i < n; i++) {
    x = digit(n, i);
    f += x;
  }
  x = gcd(f, n - 2);
  printf("%d/%d", f / x, (n - 2) / x);
  return 0;
}
