Java中“|”和“||”用法的区别
摘要:
例子: 1 int a = 5; 2 int b = 10; 3 4 if(a > 4 | b++ > 10) { 5 System.out.println("a:"+a+"\nb:"+b); 6 } 运行结果:a:5 b:11 1 int a = 5; 2 int b = 10; 3 if(a > 阅读全文
posted @ 2016-02-23 10:41 爱上分享的猪 阅读(13112) 评论(0) 推荐(1) 编辑