3 ms·
There are! But composability is easier in the languages that have generics/templates/etc. There's less passing around of function pointers and writing of custom
by dgacmu 2y ago
There are! But composability is easier in the languages that have generics/templates/etc. There's less passing around of function pointers and writing of custom comparator functions, using something like binary search or sort as an example, and the fact that those comparators can be inlined can often make the rust or C++ version faster than the "as simple to write" C version.
Obviously, all of these languages are capable of doing anything the others can. Turing complete is turing complete. But compare the experience of writing a multithreaded program that has, as part of it, an embedded HTTP server that provides statistics as it runs. It's painful in C, fairly annoying in C++ unless you match well to some existing framework, pretty straightforward in Rust, and kinda trivial in Go.
- johnisgood 2y agoWhen it comes to multithreaded programs, I much prefer Go over C, too. :)
- deleted 2y ago[deleted]