Assignment: Computer science homework
Write a complete C++ program that does the following:
a. Program prompts user to input a positive integer x greater than 1000. If the inputted value is invalid, program continuously prompts user to input a valid number. Program then finds the biggest digit of the x by using biggestDigit function (c). And prints all the prime numbers from 0 to 100 using isPrime function (b).
b. boolean isPrime(int x) tests if a number is a prime number. If the given parameter is prime, then the function returns true; otherwise, it returns false. Prime number is a number that is only divisible by one and itself.
c. int biggestDigit(int x) finds the biggest digit in the given parameter, and returns that value.