#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) {
  if (a < b) return gcd(b, a);
  if (b == 0) return a;
  return gcd(b, a % b);
}
int main() {
  ios_base::sync_with_stdio(0);
  int a, tsum = 0;
  cin >> a;
  for (int i = 2; i < a; i++) {
    int sum = 0, tmp = a;
    while (tmp) {
      sum += (tmp % i);
      tmp /= i;
    }
    tsum += sum;
  }
  int g = gcd(tsum, a - 2);
  cout << tsum / g << "/" << (a - 2) / g;
  return 0;
}
