Prime probability

5

1 votes
Easy
Problem

Given a number N,if we can select any number between 2 and N (both inclusive), find the probability that the selected number is PRIME.Express the probabilty as an irreducible fraction.

Input Format

Given a number N.

Constraints

1 <= N <=1000

Output Format

Print the required probability as an irreducible fraction. If required answer is 0, output 0/1.

Time Limit: 5
Memory Limit: 256
Source Limit:
Explanation

The number of prime numbers between 2 and 15 = 6.

Total numbers = 14

Probabilty=3/7.

Editor Image

?