fl.cpp
#include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <iostream>
#include <sstream>
#include <map>
#include <set>
#include <queue>
#include <vector>
using namespace std;
#define FOR(prom, a, b) for(int prom = (a); prom < (b); prom++)
#define FORD(prom, a, b) for(int prom = (a); prom > (b); prom--)
#define FORDE(prom, a, b) for(int prom = (a); prom >= (b); prom--)
#define PB push_back
#define MP make_pair
#define MM(co, cim) memset((co), (cim), sizeof((co)))
#define DEB(x) cerr << ">>> " << #x << " : " << x << endl;
int main ()
{
int n;
while(scanf(" 1/%d", &n) == 1) {
int y, res = 0;
for(y = n+1; y <= 2*n; y++) {
if((n*y) % (y-n) == 0) res++;
}
printf("%d\n", res);
}
return 0;
}