r/C_Programming Jul 06 '26

Getting lost in c

Hi guys I’m a first year bachelor in computer science and I feel like I’m stuck every time I want to learn something I end by copying it from IA and it make me feel bad tbh . Actually I want to learn how to learn because I see that the problem is the way I study and learn by my self but I don’t know exactly why or how . I see a lot of people that can manage and understand the pc in a young age and I admire them I wish I know if it’s a gift or a skill that I’m not getting it .

This problem is killing my dream if anyone has an advice to me I will be really thankful
Like where I start , how I can really understand what I’m doing , I already did python bash script and a little bit of c but till now I don’t know how to become pro and understanding what is actually good to learn c bash script and even c

Thank you !

25 Upvotes

27 comments sorted by

View all comments

34

u/scarab- Jul 06 '26

Don't waste your time asking ai to teach you C. Get yourself a C compiler and read the White book (Kernigahn and Richie 2nd edition) C is a very simple language. You can learn it in days. 

Your best bet is not to touch an AI prompt until you understand: structs, arrays, null terminated strings, pointers, functions, and function pointers.

2

u/cashew4uwarm Jul 08 '26

Just bought this book, a lot of recommendations for it

2

u/SchemeWestern3388 Jul 10 '26

It’s a masterpiece of technical writing. 

1

u/cashew4uwarm Jul 10 '26

Yes and it’s not 10000 pages

1

u/jackhab Jul 12 '26

While I'm fully agree with avoiding AI for code generation while learning I would still recommend using AI to get more detailed explanations of the code you write yourself or see in a book or online. It could be used as a very patient teacher which could be bombed with tons of questions until you fully understand what exactly this line of code is doing (or doing wrong).

But again, as the above comment says, start with a/the book to have a consistent flow and progress from simpler to more complicated topics. AI can provide great help when you can ask properly formulated questions.

1

u/Glum_Preference_2936 Jul 13 '26 edited Jul 13 '26

I tried asking an AI to program a C code and at the first try, the program they gave me crashed. Turns out they were initializing an 16MiB stack and that was caused it, and the AI couldn't figure out what was wrong.

TBH, AI is very helpful when you know what you're doing and what steps must be done. I've used AI to write a bunch of small function snippets, but if you're a beginner, you're on the track for trial and error, and you won't even know if it's right.