Calculating prime (Optimus?)

That brakes the code as the loop would never start, what if I wanted to know the primes between 1 and 50?