Hi All,
Why should we choose C++ for Competitive Programming?
Please give the detailed explanation with reasons. Thanks In Advance
Warm Regards, Akshay Kumar Software Developer 9310279350
№ | Пользователь | Рейтинг |
---|---|---|
1 | tourist | 3843 |
2 | jiangly | 3705 |
3 | Benq | 3628 |
4 | orzdevinwang | 3571 |
5 | Geothermal | 3569 |
5 | cnnfls_csy | 3569 |
7 | jqdai0815 | 3530 |
8 | ecnerwala | 3499 |
9 | gyh20 | 3447 |
10 | Rebelz | 3409 |
Страны | Города | Организации | Всё → |
№ | Пользователь | Вклад |
---|---|---|
1 | maomao90 | 171 |
2 | awoo | 163 |
3 | adamant | 162 |
4 | TheScrasse | 157 |
5 | nor | 153 |
6 | maroonrk | 152 |
6 | -is-this-fft- | 152 |
8 | Petr | 146 |
9 | orz | 145 |
10 | pajenegod | 144 |
Hi All,
Why should we choose C++ for Competitive Programming?
Please give the detailed explanation with reasons. Thanks In Advance
Warm Regards, Akshay Kumar Software Developer 9310279350
Название |
---|
It is very fast, noticeably faster than Java, C#, Python, Kotlin etc. Most competitions only have one time limit, and participating in C++ gives you an advantage. Even if competitions have separate time limits for slower languages, it is often less reliable (and from a problemsetter's POV, a major headache).
Some other fast languages like C and (or assembly :P) are unsuitable, because programming in them is much less convenient — you lose all of C++-s standard library, which is pretty important.
It is the industry standard, so to speak. Almost all CP-specific libraries, tutorials and code examples are written in C++. I can copy-paste someone else's FFT, dynamic CHT, geometry lib or whatever. If I participated in something else, there's a good chance that I'd have to implement a lot myself. Rust or D might be comparable to (or better than) C++ in terms of speed and standard library, but they have nothing like this kind of support.
It is supported on every platform.
Currently I see no reason to not choose C++. The only possible reason might be that other languages are more convenient to write in, but the benefits of C++ far outweigh this.