chasekaylee

chasekaylee

Do you recommend learning C?

Hi everyone! I have been in the professional industry for ~2 years now coming from a boot camp. I started a base foundation by programming heavily with JavaScript. I have various full stack experiences, and love learning everything related to computers + tech. I have recently been heavily invested in learning all about Linux, cloud development, + Elixir (random side note).

That being said, because of my background, I sometimes feel like I am behind in the core fundamentals in CS. I first started to learn programming and have the most experience with JavaScript, but sometimes I feel like it has not provided me with the solid foundation to become a proficient back end developer. I have been putting a lot of effort on data structures and algorithms (not the best but I really enjoy learning about these) and have been trying to build a solid cs foundation for myself.

Do you guys recommend me learning C to gain a more solid understanding of fundamental computer theories / how computers think? If so, I would really appreciate some of your recommended resources to get started! Thanks again for reading and any advice you have! If you recommend any alternatives I would appreciate that as well!

Most Liked

dimitarvp

dimitarvp

I am not 100% clear on your goals – they are rather vaguely stated. If you want to go the lowest possible level before reaching for assembly and machine code then sure, C can teach you how are things done in x86 / x86_64 land (not very sure it can teach you much about platforms like ARM and MIPS but it probably could). Can be useful if you are very much into programming various IoT devices, car mini-computers and in general devices where even slightly higher-level system languages (D, Rust, Nim, Zig) are a no-go – but mind you, that gap is being eliminated little by little every month.


Now for my opinions.

If you want to go low level I recommend learning C only to an extent and then reach for Zig. It’s an amazing language aimed to directly compete with C and recently its author also added very valuable integration with C compilers. I strongly recommend reading this article, it’s very insightful both for C and Zig compilation!


Kudos for reaching for Elixir. It’s a secret weapon for many (myself included) and is generally underestimated – but it has a runtime (well, Erlang has, but Elixir gets it by the virtue of stepping on Erlang) that all other languages out there can only dream of: transparent green thread multiplexing on all CPU cores/threads, lag-less operation, predictable performance even under heavy load, supervision trees / auto-restarts on minor failures, message passing between actors/processes… These are things that I and many others tried to make in C++, Java, PHP, JS, Ruby, Python and other languages over the courses of our careers – and failed every time, while Erlang has been there all along.


…If you are looking for code much faster than JS, natively compiled, and with strong static typing then definitely go for Rust. As much as I love Elixir and always will, Rust beats it in no small amount of areas: it has an absolutely fantastic community (Elixir as well; it’s one of the best communities I ever participated in!) – very smart and experienced people, amazing documentation (their official online learning book has different styles depending on if you prefer to read more or exercise more), and they are very keenly aware of the shortcomings of the language compared to stuff like C++ and Java and are working day and night to erase the gap. There is a huge amount of libraries, like anything you can think of is 99% likely already there (sadly not the case for Elixir). They are also working on having a runtime like Erlang’s (the BEAM VM) but sadly that seems far away from happening just yet – no wonder, the BEAM is 30 years old. Rust can get compiled on a plethora of platforms as well. Not as wide-reaching as C but it’s pretty close.


Haskell and OCaml are other very strong contenders. But have in mind that, especially with OCaml, you will mostly be learning on your own – there are a ton of resources out there, mind you, but stuff you take for granted (like UTF-8 strings) you have to specifically take care of in those: they have libraries for them but in general you have to be much more explicit in what you want. And those languages’ strong points do require heavy upfront learning investment to become really good at (especially Haskell’s monads).

I sit somewhere a bit higher on the stack; I’d like some things to be baseline and then build on top of that (Elixir and Rust have UTF-8 strings built-in, for example). But, you know, preference.

In case it matters, in the last several years I worked exclusively with Elixir and just recently started a job with Rust. These two languages can cover like 99% of everything I ever needed in my 18.5y of career.


Lastly, to answer the title: I recommend learning C only to an extent. Learn pointer arithmetic, learn basic vtable dispatch (emulating the OOP class/method constructs), learn stack buffers and heap memory semantics. But don’t tarry on C. Just go for other languages – Rust is my top recommendation.

Hope this helps, even if it’s largely a personal take on the topics you raised.

dimitarvp

dimitarvp

I also performed quite fine with imperative languages but… there was always something missing. I was keenly aware that I was riding on the shoulders of giants and had no real idea how stuff below worked (well, I did because I started with Assembly and C about 19y ago but I don’t know how the JS runtime works to this day). I wanted to know how the engine under the hood worked!

So I get the sentiment fully. :slight_smile:

To really bend your brain and learn a bit more about the mathematical side of programming – invest in FP. Doesn’t matter much if it’s Elixir, Erlang, LISP, Haskell, OCaml or what-have-you (although LISP is likely the closest to math and programming at the same time).

I recently bought Hands-On Data Structures and Algorithms with Rust but haven’t read it yet so can’t give you a recommendation for/against it.


The impostor’s syndrome is very real and you should to your best to fight against it. Academic prowess rarely wins the day; it’s the practical people who know technology good enough but are excellent communicators who get the big money in the end.

chasekaylee

chasekaylee

Wow… Thank you for your amazing response. I appreciate it so much. Apologies if my original goal in mind was stated very vague. Since I was originally taught programming in a way to get a job as fast as possible, learning JS, various web frameworks, NodeJS, etc. I feel like I have a gap of knowledge between myself vs “CS majors and MSCS” programmers in terms of my knowledge of theory + “core CS fundamentals” . I’ve been trying to fill that gap recently, by teaching myself various CS fundamentals and was just curious to the best way to approach that. I wanted to note I really enjoy learning and teaching myself these fundamentals in my free time (vs. forcing myself to do this). Also worth noting I have been doing fine at my current job in terms of performance. These are just my own internal thoughts.

My thoughts are still all over the place and I’m rambling, but you definitely helped me with a starting place! I guess Impostor Syndrome still sets in every once in a while :smiley:. I appreciate your help! You are definitely right about the Elixir community though. I have been starting to try and get more actively involved and it has been an amazing experience so far. Thanks again for the thorough insight and sorry again if my thoughts aren’t completely clear.

Popular General Dev topics Top

Devtalk
Reading something? Working on something? Planning something? Changing jobs even!? If you’re up for sharing, please let us know what you’...
1020 16979 374
New
AstonJ
A thread that every forum needs! Simply post a link to a track on YouTube (or SoundCloud or Vimeo amongst others!) on a separate line an...
New
AstonJ
If so, what was the last blog post you wrote… and if not, why not?
New
AstonJ
Looking at @siddhant3030’s photo from the Do you blog? thread, do you cover your computer or phone camera as a security precaution? Wha...
New
AstonJ
If you could work on any project, what would it be? :upside_down_face:
New
AstonJ
Inspired by this tweet by @dasdom Even if you take out all the damage being done by humans, our planet has about 50B years before bein...
New
AstonJ
Always interested in seeing what apps people use and how they organise their phones/home screens! Here’s mine…
New
AstonJ
Continuing the discussion from Thinking about learning Crystal, let’s discuss - I was wondering which languages don’t GC - maybe we can c...
New
OvermindDL1
What shell(s) do you use, why do you use them, and how do you have them configured? Note, this is about shell’s, not terminals, terminal...
New
jaeyson
Not trying to add more mess here but, reddit has ELI5 but i wanted to know if it’s okay to ask Elixir-specific (or outside of it) in a si...
New

Other popular topics Top

AstonJ
A thread that every forum needs! Simply post a link to a track on YouTube (or SoundCloud or Vimeo amongst others!) on a separate line an...
New
malloryerik
Any thoughts on Svelte? Svelte is a radical new approach to building user interfaces. Whereas traditional frameworks like React and Vue...
New
ohm
Which, if any, games do you play? On what platform? I just bought (and completed) Minecraft Dungeons for my Nintendo Switch. Other than ...
New
Exadra37
Please tell us what is your preferred monitor setup for programming(not gaming) and why you have chosen it. Does your monitor have eye p...
New
AstonJ
I’ve been hearing quite a lot of comments relating to the sound of a keyboard, with one of the most desirable of these called ‘thock’, he...
New
husaindevelop
Inside our android webview app, we are trying to paste the copied content from another app eg (notes) using navigator.clipboard.readtext ...
New
First poster: bot
Large Language Models like ChatGPT say The Darnedest Things. The Errors They MakeWhy We Need to Document Them, and What We Have Decided ...
New
New
AstonJ
If you’re getting errors like this: psql: error: connection to server on socket “/tmp/.s.PGSQL.5432” failed: No such file or directory ...
New
AstonJ
This is a very quick guide, you just need to: Download LM Studio: https://lmstudio.ai/ Click on search Type DeepSeek, then select the o...
New