参见英文答案 Java conditional operator ?: result type5个 Why does the ternary operator unexpectedly cast integers?2 请考虑