-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathIfSample.java
More file actions
32 lines (25 loc) · 752 Bytes
/
Copy pathIfSample.java
File metadata and controls
32 lines (25 loc) · 752 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
/*************************************************************************
# File Name: IfSample.java
# Author:
# Mail:
# Created Time: 2016年11月11日 星期五 13时16分15秒
************************************************************************/
public class IfSample{
public static void main(String args[]){
int x, y;
x = 10;
y = 20;
if ( x < y )
System.out.println("x is less than y");
x = x*2;
if ( x == y ){
System.out.println("x now is equal y");
}
x = x * 2;
if ( x > y )
System.out.println("x now is greater than y");
if (x == y){
System.out.println("You won't see this");
}
}
}