Problem Statement 
 You are a programming team coach, and your task is to put together the best possible team of three students. There are several students willing to join the team, and their ratings are given in the int[] ratings, where the ith element is the rating of the ith student. Unfortunately, some students cannot work together. You are given a String[] compatibility, where the jth character of the ith element is 'Y' if the ith student and jth student can work together, and 'N' otherwise. You must pick a team of three students such that everybody on the team can work with everybody else on the team, and the sum of their ratings is as high as possible. Return the sum of the team members' ratings, or 1 if it is impossible to pick such a team. 

Definition 
 Class:  TeamSelection  Method:  selectBestTeam  Parameters:  int[], String[]  Returns:  int  Method signature:  int selectBestTeam(int[] rating, String[] compatibility)  (be sure your method is public) 




Constraints 
  rating will contain between 3 and 50 elements, inclusive. 
  Each element of rating will be between 1 and 1000, inclusive. 
  compatibility will contain the same number of elements as rating. 
  Each element of compatibility will contain exactly n characters, where n is the number of elements in compatibility. 
  compatibility will contain only the characters 'Y' and 'N'. 
  The ith character of the jth element of compatibility will be equal to the jth character of the ith element of compatibility. 
  The ith character of the ith element of compatibility will be 'Y'. 

Examples 
0)  
 {1,2,3,4}  {"YYYY",
"YYYY",
"YYYY",
"YYYY"} 
 Returns: 9  Every student can work together with every other student. 


1)  
 {1,2,3}  {"YNN",
"NYN",
"NNY"} 
 Returns: 1  No team can be composed because there is no pair of students who can work together. 


2)  
 {1,2,3,4}  {"YYNN",
"YYNN",
"NNYY",
"NNYY"} 
 Returns: 1  

3)  
 {750, 911, 451, 578, 337, 894, 549, 620, 509, 672, 465, 562, 138, 939, 113}  {"YYNYYYNYNYYNYNN",
"YYNYNYNNYNNNYYY",
"NNYNYNNNYNNYNNY",
"YYNYYYYNYNNYYNN",
"YNYYYNNNNYNYYNY",
"YYNYNYYYYNYYNYY",
"NNNYNYYYYYNYYYN",
"YNNNNYYYYYNYYNN",
"NYYYNYYYYNYYYYY",
"YNNNYNYYNYNNNNY",
"YNNNNYNNYNYYYNN",
"NNYYYYYYYNYYNYY",
"YYNYYNYYYNYNYYY",
"NYNNNYYNYNNYYYY",
"NYYNYYNNYYNYYYY"} 
 Returns: 2744  
