Problem link I did not find any better solution in the discuss section of leetcode that's why posting here.
№ | Пользователь | Рейтинг |
---|---|---|
1 | tourist | 4009 |
2 | jiangly | 3823 |
3 | Benq | 3738 |
4 | Radewoosh | 3633 |
5 | jqdai0815 | 3620 |
6 | orzdevinwang | 3529 |
7 | ecnerwala | 3446 |
8 | Um_nik | 3396 |
9 | ksun48 | 3390 |
10 | gamegame | 3386 |
Страны | Города | Организации | Всё → |
№ | Пользователь | Вклад |
---|---|---|
1 | cry | 167 |
2 | Um_nik | 163 |
3 | maomao90 | 162 |
3 | atcoder_official | 162 |
5 | adamant | 159 |
6 | -is-this-fft- | 158 |
7 | awoo | 157 |
8 | TheScrasse | 154 |
9 | Dominater069 | 153 |
9 | nor | 153 |
Problem link I did not find any better solution in the discuss section of leetcode that's why posting here.
Название |
---|
It is very disappointed to see that useless blog gets upvotes and a lot of people comment on those blogs but I even did not got any answer of my genuine problem. I was thinking that there are so many genius coders that will answer my problem. Shame on you CodeForces community.
Sometimes the comunity is obviously being biased, but let not just focus on the vote since it is not that important, compared to the important of current knowledge — which can be easily comprehend through the color.
What's the need of it? You can write simple O(n^3) solution.
Even if sometimes gray coders make stupid questions, we should not just be so mean to those new leaner about everything. Sometimes they just curious to ask to become better. Chill :/
I don't think I can solve it
I am curious if we can really solve in linear tho hmmmm
By quick thinking, $$$O(n^2 + alphabet)$$$ is possible if you iterating each letter and increase its frequency while maintaining the maximum and the minimum
Yes, it is easy to do that. But how can we solve it less than n^2?
I am pretty sure with this kind of problem we can do $$$O(n \sqrt{n})$$$ or faster, but it seems trickier than I thought it would