#coding:utf-8 prime=[2,3,5,7,11,13] composit=[4,6,8,9,10,12] K=input() n=[i*u for i in prime for u in composit] if K in n: print 0.0277777777777777778*n.count(K) else: print 0.00000000000000000