Question: 1 Lab Objectives The following objectives will be met at the end of this lab - Declare and define variables to store input given by

 1 Lab Objectives The following objectives will be met at theend of this lab - Declare and define variables to store input

1 Lab Objectives The following objectives will be met at the end of this lab - Declare and define variables to store input given by the user Accept user input using the Scanner class Use for, while to iterate over source code Define and use a function to perform a repeated task 1.2 Lab Objectives The source code file Lab6.java that you will create in this section, is what you will upload as your submission file to Canvas by the due date for this lab. Please ensure that the source code runs on your machine and produces the correct output as required. Overall Objective: For this lab, we will write a JAVA program to count the number of Prime Palindrome numbers between 1 to 100000 (both numbers inclusive). For this section, you will create a new project in your IDE called Lab6 and create a source file called Lab6.java inside that project. The following requirements must be met to successfully complete this section - Obj.1 ((1+3+1) points] Define a static boolean function called isPrime(int num) that returns true if the parameter num is Prime or false if it is not Prime. Obj.2 [(2+6+1) points] Define a static boolean function called isPalindrome(int num) that returns true if the param- eter num is a Palindrome number or false if it is not a Palindrome number. Obj.3 [2 points] Define the main() function and use a for loop to generate numbers between 1 to 100000. Obj.4 [3 points] Within the for loop use the functions isPrime(...) and isPalindrome(...) to determine and count the number of Prime Palindrome numbers within the given range. Obj.5 [1 point] Display the count of Prime Palindrome numbers outside the for loop

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!