Question: Write a Java program that implements the following state diagram. Turn in a listing of your program, and the results of a test run with
readNumber update entry -reado exit otPrime true [n != 01/ i )notPrime = false handleZero checkPrime doDivide exit / notPrime = true [i > notPrime) writeResult [notPrime writeYes entry/ write(prime") InotPri writeNo entry/writenot prime")
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
