?:1 1116. Convert boolean values to strings 'Yes' or 'No'. Complete the method that takes a boolean value and return a "Yes" string for true, or a "No" string for false. Solution: String bool_to_word(bool boolean) { String result = "No"; if (boolean == true) { result = "Yes"; } return result; } // or String bool_to_word(bool boolean) => boolean ? "Yes" : "No"; 2022. 11. 17. 이전 1 다음