实例 Java 比较运算符 >

x
 
public class Main {
  public static void main(String[] args) {
    int x = 5;
    int y = 3;
    System.out.println(x > y); // returns true because 5 is greater than 3
  }
}
                    

输出结果

true