Some time ago, you asked n people a set of m questions about the history of your country, and you wrote down their answers. Every question had two possible answers - "yes" or "no". You divided all the people into three groups. People in the first group always gave correct answers to all the questions. People in the second group always gave wrong answers to all the questions. People in the third group gave you at least one correct answer and at least one wrong answer.
Now you want to analyze the gathered data, but unfortunately, you completely forgot which people belong to each of the three groups, and you forgot the correct answers to the questions as well. However, you're absolutely certain that there were exactly k1 people in the first group, k2 people in the second group and n - k1 - k2 people in the third group. Using this information along with the people's answers, you should be able to either restore the correct answers to the questions or determine that you made an error when noting down people's answers.
The answers that you wrote down are given in the String[] answers, where the j-th character of the i-th element is the answer given to the j-th question by the i-th person. 'N' means "no" and 'Y' means "yes". Return a String containing exactly m characters, where the i-th character is the correct answer for the i-th question ('N' for "no" and 'Y' for "yes"). If there are multiple possible Strings, return the one among them that comes first alphabetically. If there are no such Strings, return the empty String instead.
|