Describe a program to determine whether or not an integer is prime.
Respuestas de entrevistas
Anónimo
7 jun 2025
Say the integer is n, check whether n is divisible by any integer i where 2 conclude that n is prime.
Anónimo
5 mar 2019
May I ask how many coding question you had? And is it through coderpad? Many thanks!
1
Anónimo
18 abr 2019
This is an easy question, man. At least you could provide a solution with the worst complexity of sqrt(n) and average sqrt(n / log(n) ).
And next, they could move on to the case of bits shifting.