请问标红的这句话什么含义
boolean transfer=true;
transfer = (transfer == true) ? false : true;
------解决方案--------------------
三元运算符
transfer = (transfer == true) ? false : true;
等同于
Java code
if(transfer == true){
transfer = false;
}else{
transfer = true;
}
------解决方案--------------------
------解决方案--------------------