K=gets.to_i puts [2,3,5,7,11,13].product([4,6,8,9,10,12]).select{|i|i[0]*i[1]==K}.count/36.0