#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) {
  if (a == 0) return b;
  if (b == 0) return a;
  if (a > b)
    return gcd(a % b, b);
  else
    return gcd(a, b % a);
}
class Ratio {
  int p;
  int q;

 public:
  Ratio(int p, int q) {
    this->p = p;
    this->q = q;
    this->p /= gcd(p, q);
    this->q /= gcd(p, q);
  }
  void print() { cout << p << "/" << q << endl; }
};
int main() {
  int a, sum = 0;
  cin >> a;
  for (int i = 2; i < a; i++) {
    int tempA = a;
    while (tempA != 0) {
      sum += tempA % i;
      tempA /= i;
    }
  }
  Ratio A(sum, a - 2);
  A.print();
}
