题目链接:http://codeforces.com/problemset/problem/13/A
//C++代码
#include<iostream>
using namespace std;
int gcd(int n,int m){
return m==0? n:gcd(m,n%m);
}
int main(){
int n,m,i,sum=0;
cin>>n;
for(i=2;i<n;i++){
m=n;
while(m){
sum+=m%i;
m/=i;
}
}
cout<<sum/gcd(sum,n-2)<<"/"<<(n-2)/gcd(sum,n-2)<<endl;
return 0;
}