Narra123 commited on
Commit
efeee57
·
verified ·
1 Parent(s): 5864f37

Update Main.java

Browse files
Files changed (1) hide show
  1. Main.java +9 -5
Main.java CHANGED
@@ -1,8 +1,12 @@
1
  public class Main {
2
- public static void main(String[] args) throws Exception {
3
- while (true) {
4
- System.out.println("It works!");
5
- Thread.sleep(500); // wait 5 seconds
6
- }
 
 
 
 
7
  }
8
  }
 
1
  public class Main {
2
+ public static void main(String[] args) {
3
+ int a =20;
4
+ if(a%2==0){
5
+ System.out.println("Even number");
6
+ }
7
+ else{
8
+ System.out println("odd number");
9
+
10
+ }
11
  }
12
  }