I was attempting the CSES Apartments problem and here is my solution in java. I've used the two pointer approach but still I have a timeout in one of the testcases. Someone please help me understand the shortcoming in my code.
Thanks in advance.
№ | Пользователь | Рейтинг |
---|---|---|
1 | tourist | 4009 |
2 | jiangly | 3839 |
3 | Radewoosh | 3646 |
4 | jqdai0815 | 3620 |
4 | Benq | 3620 |
6 | orzdevinwang | 3612 |
7 | Geothermal | 3569 |
8 | ecnerwala | 3494 |
9 | Um_nik | 3396 |
10 | gamegame | 3386 |
Страны | Города | Организации | Всё → |
№ | Пользователь | Вклад |
---|---|---|
1 | maomao90 | 163 |
1 | Um_nik | 163 |
3 | -is-this-fft- | 160 |
4 | atcoder_official | 158 |
4 | cry | 158 |
6 | awoo | 157 |
7 | nor | 155 |
8 | adamant | 154 |
9 | TheScrasse | 153 |
10 | Dominater069 | 152 |
CSES Apartments- Timeout in java
I was attempting the CSES Apartments problem and here is my solution in java. I've used the two pointer approach but still I have a timeout in one of the testcases. Someone please help me understand the shortcoming in my code.
Thanks in advance.
Rev. | Язык | Кто | Когда | Δ | Комментарий | |
---|---|---|---|---|---|---|
en1 | 69_LoVeRGuY | 2021-05-04 18:43:36 | 367 | Initial revision (published) |
Название |
---|