#include <bits/stdc++.h>
using namespace std;
int main() {
  int x;
  cin >> x;
  int num, sum = 0, n = 0;
  for (int base = 2; base < x; base++) {
    n++;
    num = x;
    while (num > 0) {
      sum += (num % base);
      num /= base;
    }
  }
  for (int i = n; i > 1; i--) {
    if (sum % i == 0 && n % i == 0) {
      sum /= i;
      n /= i;
      i = n + 1;
    }
  }
  cout << sum << "/" << n;
  return 0;
}
