← All problemsSign in

Prim Function

Given function $Prim(x)=$Number of primes in the prime factorization of x. For example, $18=2*3*3$. So, $Prim(18)=3$ Given $L$ and $R$, Find number of $x$ between $L$ and $R$(both inclusive) such that $Prim(Prim(x))=1$ ###Input: - First line will contain $T$, number of testcases. Then the testcases follow. - In each testcase, A single line will contain two integers $L$ and $R$ #

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.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start