r/C_Programming • u/WhateverHowever1337 • Jul 14 '26
Are LLMs good at C?
I am a CS student and I am not enjoying the thought of being an LLM prompter when I graduate.
is LLM usage in projects with C as a main language as bad as other fields? or is code still being manually written
0
Upvotes
11
u/Substantial_Job_2068 Jul 14 '26
I'm a software dev with 10+ YOE and I have not been forced to use an LLM. We can use Claude if we want at work and some do, the common denominator is that the devs who are not very passionate about coding and aren't very good at it, use LLMs and are fascinated by what it can do. And I have not seen any productivity increase from them, it's more like a fun toy for them.
11
u/v_maria Jul 14 '26
yes
19
u/bluetomcat Jul 14 '26
It can be good at locally-scoped problems with clear boundaries. Say, "vectorise this loop with SIMD intrinsics", or "implement a B-tree for this purpose". Maybe you don't know exactly how to use them, and you don't want to spend hours reading docs or the details of a particular data structure. This stuff has been written many times and the LLM has absorbed the patterns. Still, you have to be able to understand the output and be comfortable with it.
It is not good when you prompt it to "write this whole program for me". The code will certainly be sub-standard in comparison to an experienced programmer, not easy to maintain, full of semantic anomalies, and will look like disparate fragments joined with duct tape, not the result of a cohesive thought process.
7
u/Maqi-X Jul 14 '26
They are good at generating working code but bad at generating good code
4
u/[deleted] Jul 14 '26
Doesn’t matter if it’s good or not at coding there will always be someone who will force you to use an LLM and once you use one it’ll be hard to break out of it.
5
u/McDonaldsWi-Fi Jul 14 '26
Don't forget you're on reddit, asking if "LLM is good?". You are going to have a lot of bots/boosters tell you how great it is.
In reality /u/bluetomcat said it best. If you keep the scope small it can generate decent stuff, anymore more and it turns to shit quickly.
Do your brain a favor and use LLMs as little as possible and learn this stuff the hard way.
2
u/Amr_Rahmy Jul 14 '26
It’s much better if you understand how to structure a project. Software design and dataflow.
I use ChatGPT as a web search. A Google alternative. It’s as good as the information online, stackoverflow, reddit, ..etc.
It’s also as bad as the information online which is not always good or the way I want to write my code.
If you can’t write the code manually using information online, libraries, and available tools, ai will seem like it works until it doesn’t which will be very soon then you will be lost as to what went wrong and how to troubleshoot.
2
u/imperfect40 Jul 14 '26
It's absolutely dire at verilog
2
u/eXl5eQ Jul 14 '26
Frontier LLMs today are extremely good at coding, but not as good at programming.
An LLM can write a thousand lines of code in minutes, and compiled without any error at the first try, which I bet almost no human can do. But the code they write can be suboptimal, inefficient, unstable, or even doesn't work as expected at all.
You can have an LLM to generate code for you. But it's always you, the programmer, be responsible for the code quality. You have to know what do you want to code to be like, and keep a close eye on what the LLM is doing.
I wouldn't suggest anyone code with AI in 2025 because it's just a waste of time. It take crazy amount of time to write prompts to make sure everything work correctly. But in 2026, I think you can give it a try as sometimes they can actually save your time and effort.
3
u/Nxllify__ Jul 14 '26
No. But you will probably still be forced to use LLMs.
1
u/Disastrous-Team-6431 Jul 14 '26
I have been a professional software developer for 12 years, and was programming as a hobby before that for something like 20 years. So, through the 90s and early 2000s.
I have only recently started using LLMs extensively for some of my projects. At work I don't use them much. (I don't work in C any more but I used to.)
I want to say two things that might be useful. One: when using LLMs to any extent at all, what differentiates you from someone else will be understanding of the underlying processes. Full stop. Paradoxically, I think even if the job is python web dev heavy LLM assistance, I think more C makes you better than more python. This is an oft-parroted truism, and it's not 100 percent true 100 percent of the time, but I think LLMs make it more true - not less. Learn C well. Assembly too. Then haskell.
Two: there are LLM-driven 10x-ers for sure. Whether or not they'd be so productive and good without LLMs is kind of moot - on that, I want to say that comparison is the thief of joy. Someone will be faster and better than you at some tasks. Always. It doesn't matter if it's because they understand their tooling better, coded machine learning models in assembly when they were 12 or are prodigies who grew up as a secret Moldovan supermutant program. Don't let anyone else's story be your story.
1
u/Meshuggah333 Jul 14 '26
If you already know C well, yes. But you need very good specs, beat the LLM into doing exactly what you want, and you need to do detailed code review. IMO they're better as an exploration tool to design a project, and writing simple boiler plate code, the rest being for you to write. Using a tool like OpenSpec definitely helps.
1
u/mikeblas Jul 17 '26
There are lots of cliche interview questions, like "reverse a string" or "detect a palindrome" or implementing
atoi()oritoa(). Seems trivial since "passive" searching could find answer for these readily.One of the "unique" questions I used to ask (which I'm sure is still on the Interbutts somewhere, anyhow) is to fill an array of integers in a spiral pattern. Lots of candidates would flail at it. Off-by-one errors, other boundary conditions, struggling to find some closed "straight" iterative solution, struggling to nest loops.
ChatGPT did it correctly on the first try, no problem: https://chatgpt.com/share/6a5a9402-4ddc-83e8-93b9-0de926cb09fa
Of course, there's lots more do doing work in real life than there is to solving one programming stunt on an interview loop. So maybe that's where people should focus developing their skills: Identifying which problems to solve, and in which order to solve them, has always been a challenge. (Reddit, for example, fucks that up six ways sideways.) AI can generate a solution you've already identified, but I don't think it's so hot finding a solution to implement in the abstract.
-3
u/sswam Jul 14 '26
Many LLMs are excellent at C, with a little prompting for good style.
As for your concerns ... I don't know, writing code entirely by hand is really a lot of work, and debugging C can be a pain in the ass. Programmers end up solving fairly easy but annoying problems and variations over and over again, which is stressful, and your hair might fall out like mine did!
On the other hand, for example, I was able to write a very solid caching filesystem in C, using fuse, with the help of Claude in an hour or two. Claude did at least 95% of the work. The filesystem needed very little if any debugging as I recall. I've been running it as an important part of my AI chat service for many months, and I haven't had any problems with it. That's 347 lines of excellent, well-documented C code that I'm very glad I didn't have to write and debug by myself. By the way, all the other broadly similar caching filesystems for Linux that I tried - before resorting to writing one with Claude - were either broken or grossly overcomplicated and unsuitable for what I need.
It's like being promoted to a software architect, who can program well, but also has an extremely fast and capable developer helping (i.e. Claude). He can help with the architecture and design too, of course. And AIs are super helpful for analysis paralysis, or making tricky decisions. I'm so much less stressed about programming now, with AI help, and I enjoy it much more, and I can get a lot more done.
I'm not a "vibe coder" flying blind with no programming expertise, I'm a very strong senior developer who is grateful for the help. I still do plenty of coding and most of the design myself, but I use AI whenever I can to help speed things up. I'm often able to build useful tools that I simply wouldn't bother with if I had to write all the code. If I said to Claude Code or Cursor, "make me a magical chat app", the results would not be the same as what I'm doing now, where we are collaborating at every level.
TL;DR I think AI can be fantastically helpful for strong programmers in many ways.
-2
u/Rigamortus2005 Jul 14 '26
Yes.
0
u/[deleted] Jul 14 '26
[deleted] — view deleted comment
1
u/[deleted] Jul 14 '26
[removed] — view removed comment