Not-so-parallel prime number verification
Testing for primality is one of the first programming assignments most programmers encounter at school, almost after writing their ‘Hello World’ program. OK, maybe not exactly that early, but you get the point.
What is a prime number?
Let’s first understand why we are so interested in testing whether an integer number is prime. An integer number is considered prime if its only divisors are 1 and itself. Here we are talking about integer division, of course; you can always divide an integer if the expected result is a real number, but that is another mathematical argument.
Warning!
We are NOT using any mathematical formality or rigor here, and we are just discussing certain properties of prime numbers. So for all the mathematicians out there, we would like to request some artistic license (if that is even possible when dealing with honorable mathematics!).
This is a fundamental characteristic...