Skip to content

Commit

Permalink
feat(3.1.4): Finished U3_L1_Activity_Four
Browse files Browse the repository at this point in the history
  • Loading branch information
101zh committed Oct 6, 2023
1 parent c8676ad commit a595fda
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions src/main/java/Unit3/U3_L1_Activity_Four.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package Unit3;

import java.util.Scanner;

public class U3_L1_Activity_Four {
public static void main(String[] args){
Scanner scan = new Scanner(System.in);
System.out.println("Please Enter an Integer:");
int x = scan.nextInt();
if (x%2==0) {
System.out.println("Divisible by 2!");
}
if (x%3==0) {
System.out.println("Divisible by 3!");
}
scan.close();

}
}

0 comments on commit a595fda

Please sign in to comment.