6 ms·
It's slow because C++ compilers are slow. Python isn't so slow as to be the bottleneck here.
by devinj 15y ago
It's slow because C++ compilers are slow. Python isn't so slow as to be the bottleneck here.
- wbhart 15y agoThat's right. In fact, if Python were used to incrementally compile to assembly, it actually mightn't be too bad. There'd be a relatively short delay every time you pressed the enter key as the new bit got compiled. The problem with the approach taken is that it compiles everything you ever typed every time you type something. I honestly can't think of a worse combination. C++ is the language, you need a Python interpreter to run it. And there's no incremental compilation, so it just gets slower and slower the more you do. People who write stuff in Python need to realise that sometimes you can't solve a problem just by wrapping something in Python. Occasionally you need to do some actual work. I'm afraid I see this all too often.