#!/usr/bin/env python3 #fileencoding: utf-8 prime = [2,3,5,7,11,13] synth = [4,6,8,9,10,12] K = int(input()) count = 0 for i in prime: for j in synth: if i*j == K: count += 1 print(count/36.0)