I'm newbie and I'm solving problems in C++, but which one is better c++ or python, should i switch to python or better to stay in C++! Thank you!
# | User | Rating |
---|---|---|
1 | tourist | 3985 |
2 | jiangly | 3814 |
3 | jqdai0815 | 3682 |
4 | Benq | 3529 |
5 | orzdevinwang | 3526 |
6 | ksun48 | 3517 |
7 | Radewoosh | 3410 |
8 | hos.lyric | 3399 |
9 | ecnerwala | 3392 |
9 | Um_nik | 3392 |
# | User | Contrib. |
---|---|---|
1 | cry | 169 |
2 | maomao90 | 162 |
2 | Um_nik | 162 |
4 | atcoder_official | 161 |
5 | djm03178 | 158 |
6 | -is-this-fft- | 157 |
7 | adamant | 155 |
8 | awoo | 154 |
8 | Dominater069 | 154 |
10 | luogu_official | 151 |
I'm newbie and I'm solving problems in C++, but which one is better c++ or python, should i switch to python or better to stay in C++! Thank you!
Name |
---|
For competitive programming, C++ almost always wins, but knowing python would help in problems that require to work with big numbers. Maybe you can avoid it, but if solution with big numbers is easier, it's better to just code it in python
C++, I use python and sometime i just stuck on problem due to TLE but when somehow i do it with C++ it got AC so C++ is of course better than python don't switch on python.
Well if you are already writing code in c++, then continue writing code in c++. Why is it better? C++ is simply more functional and faster. BUT if you have to work with long numbers (more then 128 bits) people usually use python.
Well, there are some pros and cons of both: C++ has better execution time, with C++ you are more likely to find implementation of a certain algorithm or data structure, each problem can be solved in C++ (unlike python), it also has broad variaty of built-in data structures: red-black trees, hash tables etc. On the other side, there is python: it has extremely easy syntax but there are some issues with memory (python consumes tons of it), standard input is kinda slow. Although python is very slow, it's still viable.