code: public static boolean overlap(@Nullable String[] as, @Nullable String[] bs)
    {
      if (as == null || bs == null) {
        // They only have overlap if both are null.
        return as == null && bs == null;
      }
      if (as.length == 0 && bs.length == 0) {
        return true;
      }
  
      for (String a : as) {
        for (String b : bs) {
          if (Objects.equals(a, b)) {
            return true;
          }
        }
      }
  
      return false;
    }
docs: overlap returns true when: as and bs have one or more elements in common,
  as and bs are both null, or as and bs are both empty.