private static String findMatchInArray(String strToMatch,String[] matchInArray,String[] returnInArray){
  for (int i=0; i < matchInArray.length; i++) {
    if (strToMatch.equals(matchInArray[i])) {
      if (i < returnInArray.length) {
        return returnInArray[i];
      }
 else {
        return null;
      }
    }
  }
  return null;
}

private static String findMatchInArray ( String strToMatch , String [ ] matchInArray , String [ ] returnInArray ) { for ( int i = 0 ; i < matchInArray . length ; i ++ ) { if ( strToMatch . equals ( matchInArray [ i ] ) ) { if ( i < returnInArray . length ) { return returnInArray [ i ] ; } else { return null ; } } } return null ; }
finds a match of the given string in the given array , and returns the element at the same index in the returninarray
