Question: please answer questions 1, 2 & 3 1. Glven an integer input n, write an algorithm in Coral to check if the number is a

please answer questions 1, 2 & 3  please answer questions 1, 2 & 3 1. Glven an integer
input n, write an algorithm in Coral to check if the number

1. Glven an integer input n, write an algorithm in Coral to check if the number is a prime number. Put "Prime" to output if n is prime, and put "Not Prime" if it is not. 2. Below is a modified searching algorithm that eliminates the use of the flag but achieves the same behavior: Cl Deelise and read inpets intregor a integer) integer array(z) A integer 1 n= Qet next input x - Cet next input A. esize =B 1=0 vhile (i

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!