5 ms·
Why is still the learning curve for C so high? * Why can't the learning curve be solved using tools? * Why don't we actively promote more higher level languag
by orsenthil 7y ago
Why is still the learning curve for C so high?
* Why can't the learning curve be solved using tools?
* Why don't we actively promote more higher level languages which are implemented in C (by fewer people)?
- pantalaimon 7y agoDo you find the learning curve for C to be high? I find it quite the opposite. It's a simple language with only a few concepts to learn, once you got those, that's it. There might be some preprocessor tricks you'll pick up later, but the base language and library is pretty comprehensive IMHO.
- orsenthil 7y agoC is indeed a very small language. But the expressive power of C for real-world problems brings a huge learning curve in terms of organization, tracking, and understanding.
- darepublic 7y agoComing from python/js I found it to be high. Mostly because of the memory management/ making sure I call free correctly etc. In many cases where I would plow ahead in programming, with C I had to stop and would feel dread. A lifesaver for me was using C/C++ Repl environments where I could quickly prototype or sanity check things I was doing.
- pantalaimon 7y agoThe trick is to just not use `malloc()` and `free()` unless absolutely necessary ;)
- throw_m239339 7y ago> The trick is to just not use `malloc()` and `free()` unless absolutely necessary ;) The problem is that often C programmers have to deal with API and libraries they didn't write themselves to solve their problems, thus are forced to use constructors and destructors even when they don't want to.
- throw_m239339 7y ago> It's a simple language with only a few concepts to learn I mean by that logic, Assembly could be deem even simpler, yet writing OR reading programs in Assembly is absolutely not simple at all. At the end of day, one has to write programs that solve (complicated) problems, and learning how to do that in C is difficult, thus the learning curve deemed higher when it comes to writing professional C. I can guarantee you that writing professional Go or Java and writing correct programs in both takes way less effort than with C, for use cases that would make Go or Java viable.
- quelsolaar 7y agoModern assembly language has a huge set of instructions, that make them hard to learn, but the concept is still easy to learn.
- DougGwyn 7y agoMany antique computers are simulated by SIMH. If you have the corresponding software, you can operate on your desktop a simulated computer's software development system. For example, DEC VAX (VMS or Unix) has a relatively simple and sane assembly language.
- quelsolaar 7y agoI think, learning a tiny bit of assembler, even if in an emulator, is very valuable to teach the basics.
- NickDunn 7y agoI think that C provides fewer layers of abstraction than other languages. This requires the programmer to deal with memory management, treat strings as an array of characters, and other things that the majority of high-level languages conceptualise, so that the human mind deals with it more easily. This provides advantages and disadvantages, as it requires more thought and understanding to write the code but also allows the use of low-level features. The lack of tools to solve any learning issues is probably down to the programmer needing the right conceptual understanding and the requirements placed on anyone using the various features of the language.
- Tronic2 7y agoSyntax of pointers. Easy to use high level languages make extensive use of pointers (i.e. all their variables are actually pointers) but beginners cope with them because no stars or ampersands are required, with the help of GC. Of course they'll get bitten soon and often because it is too easy to create copies of pointers rather than copies of full data structures, and without understanding pointers it's hard to grasp why that happens.
- bumblebritches5 7y agoI taught myself C from just reading code and trying to contribute to a few projects right out of high school, no books, no school. So I don't think C has a very high learning curve, C++ on the other hand...