当前位置:网站首页>Andque.

Andque.

2020-11-07 16:54:23 osc_0vfknl5u

package com.yingyong.day02;

public class AndQue {

public static void main(String[] args) {
    // TODO Auto-generated method stub
    int a,b;
    boolean k;
    a = 15;
    b = 20;
    k = a>20 && b++>15;
    // false &&   Because the first expression is false , So the following expression system automatically ignores 
    // k=false   b=20
    System.out.println("k=" + k);
    System.out.println("b=" + b);

}

}
result :k=false
b=20

版权声明
本文为[osc_0vfknl5u]所创,转载请带上原文链接,感谢