code: private static char maybeStripMarkers(String symbol, char fallback) {
          final int length = symbol.length();
          if (length == 1) {
              return symbol.charAt(0);
          }
  
          if (length > 1) {
              char first = symbol.charAt(0);
              if (first =='\u200E' || first =='\u200F' || first =='\u061C') {
                  return symbol.charAt(1);
              }
          }
  
          return fallback;
      }
docs: Attempts to strip RTL, LTR and Arabic letter markers from {@code symbol}. If the symbol's
  length is 1, then the first char of the symbol is returned. If the symbol's length is more
  than 1 and the first char is a marker, then this marker is ignored. In all other cases,
  {@code fallback} is returned.