My first project in nearly 2 months... If the number is bigger than 100, it will ask you whether you want to employ Time-Saving mode. Information below.
Yeah, so I decided I'd try and make a few more complex projects, and here is the first one! It's called "Prime Number Calculator", and it check ANY number to see whether it's prime! (wow.) Unfortunately, to scan a number for factors is tedious, especially if it's something big (over a million). So, I've employed a few Time-Saving tactics: • Time-Save Mode: As soon as it detects the first factor, it stops and tells you whether it's prime or not. • Ruling out unnecessary numbers: If a number is 1 or smaller, it automatically tells you that it's too hard to calculate. Also, if the number is even (and bigger than 2), it just tells you right out that it's not prime. • Multiple Checkers (WIP): I'll probably do this some point in the future, but the basis of it is that you have one of those divisor variables checking every 1st odd number, 2nd odd number, 1st even number, 2nd odd number, and I could just keep adding divisor checkers until huge numbers can be calculated swiftly.