What actually the problem is? Not getting meaning of question?
Prime Visits question
@dheerajk_7 The problem is pretty simple as a number has two divisors means the number should be prime as first divisor is 1 and second is the number itself. So, you are supposed to find the count of prime numbers between two given prime numbers a and b.
Hope this helps 
Done the way you told but showing time limit exceed error also i have used sqrt method to find prime numbers
for one last test case
@dheerajk_7 You have to use Sieve of Eratosthenes to generate the prime numbers. Else it will give TLE. The lecture video of that is available in the Number Theory Section. Attempt this question again after learning that.
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.