随笔分类 -  operator-java

摘要:package operator; public class Demo06 {//位运算 public static void main(String[] args) { /* A = 0011 1100 B = 0000 1101 A & B = 0000 1100 A | B = 0011 11 阅读全文
posted @ 2022-02-22 19:59 苏三说v 阅读(29) 评论(0) 推荐(0) 编辑
摘要:package operator; //逻辑运算符 public class Demo05 { public static void main(String[] args) { //&& 与(and) ||或(or) 非(取反) boolean a = true; boolean b = false 阅读全文
posted @ 2022-02-21 17:12 苏三说v 阅读(180) 评论(0) 推荐(0) 编辑
摘要:package operator; public class Demo04 { public static void main(String[] args) { // ++ -- ,自增 ,自减 一元运算符 //重点执行的时机不同 int a = 3; int b = a++; //执行完这行代码后 阅读全文
posted @ 2022-02-21 16:46 苏三说v 阅读(30) 评论(0) 推荐(0) 编辑
摘要:package operator; public class Demo03 { public static void main(String[] args){ //关系运算符返回的结果: 正确,错误 通过布尔值来表示 true false int a = 10; int b =20; int c = 阅读全文
posted @ 2022-02-21 16:25 苏三说v 阅读(69) 评论(0) 推荐(0) 编辑
摘要:package operator; public class Demo02 { public static void main(String[] args) { long a =123123311231231L; int b =123; short c =10; byte d =8; System. 阅读全文
posted @ 2022-02-21 16:20 苏三说v 阅读(20) 评论(0) 推荐(0) 编辑
摘要:package operator; public class Demo01 { public static void main(String[] args) { //二元运算符 int a =10; int b =20; int c =25; int d =25; System.out.printl 阅读全文
posted @ 2022-02-21 16:19 苏三说v 阅读(24) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示