#include <bits/stdc++.h>
using namespace std;
int GCD(int x, int y) {
  int r = x % y;
  while (r != 0) {
    x = y;
    y = r;
    r = x % y;
  }
  return y;
}
int main() {
  int A;
  cin >> A;
  int X = 0, Y = A - 2;
  for (int base = 2; base < A; base++) {
    int n = A, sum_of_digits = 0;
    while (n != 0) {
      sum_of_digits += n % base;
      n /= base;
    }
    X += sum_of_digits;
  }
  int gcd = GCD(X, Y);
  X = X / gcd;
  Y = Y / gcd;
  cout << X << "/" << Y;
  return 0;
}
