Given a string text, return the maximum number of instances of the word "balloon" that can be formed using letters in text. Each letter can only be used once.
text = "nlaebolko"1text = "loonbalxballpoon"2b×1 a×1 l×2 o×2 n×1textl and o appear twice in "balloon" → divide counts by 2min(freq[b], freq[a], freq[l]/2, freq[o]/2, freq[n])Each "balloon" consumes one b, one a, two l's, two o's, and one n. The number you can spell is limited by whichever letter runs out first — the bottleneck. Dividing l and o by 2 converts raw counts into "how many balloons" each letter supports.