package operator;
public class Demo11 {
public static void main(String[] args) {
//关系运算返回的结果:真确,错误 布尔值
//if
int a = 10;
int b = 20;
int c = 21;
//取余 模运算
System.out.println(c%a); //c/a 21/10 = 2...1
System.out.println(a>b);
System.out.println(a<b);
System.out.println(a==b);
System.out.println(a!=b);
}
}
operator study Hard.11
最新推荐文章于 2022-02-24 03:51:56 发布