#include <bits/stdc++.h>
using namespace std;
int ggcd(int a, int b) {
  if (a == 0 || a == b) return b;
  if (b == 0) return a;
  return ggcd(a % b, b % a);
}
int main() {
  int a, sum = 0;
  cin >> a;
  for (int i = 2; i < a; i++) {
    int temp = a;
    while (temp) {
      sum += (temp % i);
      temp /= i;
    }
  }
  int k = ggcd(sum, a - 2);
  cout << sum / k << "/" << (a - 2) / k;
}
