3 ms·
I love the compatibility between C and Python. Maybe off-topic, but in which language of theese two do you find a joy to program in? As for me, Python's featu
by wheelerof4te 5y ago
I love the compatibility between C and Python.
Maybe off-topic, but in which language of theese two do you find a joy to program in?
As for me, Python's features are godsend. Only, sometimes I want that procedural simplicity of C.
I feel dirty trying to emulate C coding style in Python, even when it makes sense.
- SoylentOrange 5y agoI would stay away from writing any program in C unless it is absolutely 100% necessary for your use case. For example, if you’re working on a large existing C code base like the Linux kernel. There are much better modern alternatives to get comparable speed for new projects. Many projects that used to be written in C are being rewritten in either C++ or Rust for better memory safety and reasoning about the memory model. Disclaimer: I did my PhD (several years ago) in a systems and networking lab and most of the code I wrote was in C. Now for example modern kernel modules tend to be written in Rust if possible, while such an option was not available while I was working there
- pjmlp 5y agoAnd when using C++, for 99% of the use cases it is perfectly fine to leave bounds checking and iterator validation enabled in release code as well.
- eternityforest 5y agoI kinda hate writing real programs in C. The only time it's vaugely enjoyable is with sub 100 line embedded stuff. Otherwise, it's near the bottom of my list of languages I'd like to use. Not actually at the bottom, I'd choose it over Forth and ASM, but.... I haven't written it for anything but a microcontroller in years. I don't really do much outside of Python and JS in general these days. Python's performance is basically the same as C, because... There's already a C extension for everything! I'm really not even a fan of compiled languages in general especially not for open source work. Things like plugin architectures are a lot easier in dynamic everything is a dict type languages. But C sure is good at being ubiquitous! I appreciate the heavy standardization.