IRREDUCIBLE FRACTIONS
CodeChefOpen on judge ↗
One day Sarah is playing a game with her sister "Factomber" in which Sarah give her a no. N & she needs to count the no. of "special fraction" from 1 to N! & the special fraction must be between 0 and 1(exclusive). A fraction is special fraction iff it is irreducible fraction(in form of a/b, where a & b are relative prime) & a*b should be factomber( a number of the form X! ) Eg: 2,6,24,120 etc ar
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start