Question: im using java for IDE C Pretest: Unit 3. Looping and repetition Write a program that checks to see if a number (entered by the
C Pretest: Unit 3. Looping and repetition Write a program that checks to see if a number (entered by the user) is prime. Remember that a prime number is a number that is only divisible by itself and one. Wangi Delicate cable Smart well MacBook Pro 3 20 *** 15 14 13 12 71 * A & 7 # 3 $ 4 % 5 ! 1 0 9 8 6 N 0 Y UI T R E Q W 59%3Fri 12.14 PM ace-helloworld shared/stc/main/java/Quizunit2.java - Eclipse IDE T109.91 Update Apple ID Settings Some account services will not be helloworld.shared/pom.xml Simple1.jwa Homework 1.java Qulzunit2 available until you sign in again. 1 import java.util.Scanner; 2 public class Quizunit2 { 3 I 40 public static void main(String[] args) { // TODO Auto-generated method stub 5 6 7 8 } 10 ile 12 13 14 15 16 17 18 int number = 23; boolean flag- false for(int i = 2; ic number/2 # i) { // condition for non prime number if (number i = ) { flag = true; break; 3 2. Problems Javadoc Declaration Console X3 **
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
