KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > CommonSubExp


1     /*
2  * Created on Dec 21, 2004
3  *
4  */

5
6 /**
7  * @author jlhotak
8  */

9 public class CommonSubExp {
10
11     public static void main(String JavaDoc[] args) {
12         
13         int x = 3;
14         int y = 9;
15         int b = 9;
16         int c = 4;
17         
18         if (x < y){
19             x = b + c;
20         }
21         else {
22             y = b + c;
23         }
24         int z = b + c;
25     }
26     
27     
28 }
29
Popular Tags