here is the solution to find a number is prime or not
//javascript
function isPrime(num){
if(num <= 1) return false;
if(num <= 3 ) return true;
if(num%2 === 0 || num%3 === 0) return false;
return true;
}
Prime Number or Composite Number?? How to know if the number is prime or not? #fastandeasymaths
#How to find prime numbers between 1-100 in 5 seconds#For competitive exams#short#shorts
Prime Numbers - Magic Trick!! - Part 1 | Fun Math | Don't Memorise
Prime Numbers | Composite Numbers | Prime/Composite numbers 1 to 100 to 1000 | Concept/Facts/Rule