- 单等号是赋值操作
- 双等号是判断操作,返回boolean类型
boolean b1 = true;
boolean b2 = false;
System.out.println(b2 == b1); //false
System.out.println(b2 = b1); //true
boolean b1 = true;
boolean b2 = false;
System.out.println(b2 == b1); //false
System.out.println(b2 = b1); //true