196 views
0 votes
0 votes
Write a program in JavaScript that accepts an integer greater than 2 and tells whether
it is a prime number. Note that JavaScript has if and while statements with the same
syntax as C and Java. The modulo operator is %. If you need the square root of x, use
Math.sqrt (x).

Please log in or register to answer this question.

Related questions

0 votes
0 votes
0 answers
1
ajaysoni1924 asked Mar 19, 2019
208 views
Some cybersquatters have registered domain names that are misspellings of commoncorporate sites, for example, www.microsfot.com. Make a list of at least five such domains...
0 votes
0 votes
0 answers
4