请问高手,这个怎么运行不seconds = (seconds == 0) ?: 180 ?: seconds - 1;
private int seconds=180;seconds = (seconds == 0) ?: 180 : seconds - 1;
当运行时总是报无效表达式":","?:" --------------------编程问答-------------------- seconds = (seconds == 0) ? 180 : seconds - 1; --------------------编程问答-------------------- ?:--> ? --------------------编程问答-------------------- seconds = (seconds == 0) ? 180 : seconds - 1;
三目运算符是? : --------------------编程问答-------------------- seconds = (seconds == 0) ? 180 : seconds - 1;
补充:.NET技术 , C#