code: public static int maxCount(final Multiset<?> multiset) {
      int ret = 0;
      for (final Multiset.Entry<?> entry : multiset.entrySet()) {
        if (entry.getCount() > ret) {
          ret = entry.getCount();
        }
      }
      return ret;
    }
docs: Gets the maximum count of any element in a {@link Multiset}. This will be zero if the
  {@code Multiset} is empty.