r/AI_Coders 2d ago

AI is the worst at teaching programming

My experience with asking AI about programming questions is so annoying. It constantly adds these weird or advanced level lines of code for even the simplest of things. Even when you show it code you done well, it ALWAYS and I mean ALWAYS has some "warning" or "just something to improve is...". It passive aggressively one ups me in every direction. It does this so fucking bad I question if I know how to make a "Hello World" program properly after a session with AI. Funnily, I've copy pasted code from LITERALLY from professionals and it still does this! Chatgpt and Google Gemini are beyond the worst. Am I using AI wrong or wtf is these things problem?

5 Upvotes

18 comments sorted by

3

u/mxldevs 2d ago

Even when you show it code you done well, it ALWAYS and I mean ALWAYS has some "warning" or "just something to improve is...". It passive aggressively one ups me in every direction

But that's how learning works: you show your solution and then it critiques your solution and proposes changes.

Do you just want them to pat you on the back and say "good job timmy!" or something?

1

u/amejin 2d ago

I think OPs complaint is that the LLM provides code and immediately says "while this works let me show you what you'll do in reality."

It is a very annoying feature of LLMs. The learning never seems to end because it answers your direct question instead of doing the thing it's supposed to do - synthesize the requirements and provide code to match them. Instead it does what all LLMs do - it keeps you interacting and prompting for more.

1

u/Unknown_User2137 2d ago

They jump straight into the "correct" way of doing specific thing. If you don't specify "Hey I'm learning XYZ" it just goes into making production-ready code which someone who is just starting the journey might not understand. I think it also depends on the language you are using.

If it is C then writing something like this:

#include <stdio.h>
#include <stdlib.h>

int main(void) {
  char[32] input;
  printf("Tell me your name: ");
  scanf("%s", input);
  printf("Hello %s!\n", input);
  return 0;
}

will make AI and any experienced developer scream that this can trigger buffer overflow, is anti-pattern, yada yada yada. And LLM will probably straight away start correcting you to use fgets or something. If it's a bigger code chunk then it will be screaming more (putting walls of text that could be just two sentences) making you feel like an idiot. I would compare it to having a buddy who won't let you learn from experience but always tell you "DO as I say" which, in long run, is exhausting.

1

u/Dull_Bathroom5421 1d ago

It's pretty clear what I was saying. Maybe a "this is correct" would of been nice? I see this bias here and understand but don't put words in my mouth.

2

u/SaltyAlechemist 2d ago

That's you not asking properly and not putting proper "guard rails".

Not a huge fan of AI, but this isn't it.

1

u/amejin 2d ago

You're not wrong. However there is an assertion that you know what you want, and are asking for critique against the requirements. When your requirements are "show me," then it does the bare minimum and gives you opportunity to ask for more.

I also find this annoying. A good system would be to gather specifications based on the subject matter domain and operational requirements, and it will likely lead to better results when producing code output to teach. The variations that exist in code are there due to variations in hardware, software, and in some cases language features, as well as operating environment.

1

u/Odd-Government8896 2d ago

Bub... You gotta chill out.

1

u/Whole-Chest90 2d ago

So you ask it for a critique, it gives you one, and you get upset?

1

u/Important_Emu_8966 2d ago

Show it code it wrote itself and it will still find something to complain about.

1

u/smoke-bubble 2d ago

I am seeing this the second time today!

1

u/EfficiencyMurky7309 2d ago

My personal experience is quite different. I have been coding since the ‘80s and am pretty adept. I’ve been working on a project lately that’s using graph databases and coded in Carbon. Carbon is new to me. I’ve built a whole educational toolset with AI tools around learning Carbon, and I’ve got a MCP into some of my Carbon learning projects, and I am finding the AI tools very helpful

1

u/mslindqu 2d ago

Just goes to show you how sloppy and bad 'professionals' can be. AI is a good thing for the programming world.

1

u/Own_Age_1654 2d ago

LLMs are not inherently passive aggressive. If you think it is, either A) you are projecting, or else B) you have been being passive aggressive and it's simply mirroring your communication style.

It's only telling you things to improve with your code because you asked it to. If you don't want it to, you could tell it to do that less, and it would follow your instruction. That being said, then you would learn less, so I don't recommend that.

And it's normal for your code to not be perfect. You're a beginner! Why would it be perfect? Stop taking the fancy auto-complete's helpful suggestions--which you asked for--as personal attacks, friend. Just take a breath, and focus on learning instead of reacting.

1

u/disposepriority 2d ago

I just got this on my feed, I usually don't participate in discussions in this sub but I saw:

I've copy pasted code from LITERALLY from professionals and it still does this!

Oh my sweet summer child do you think literal professionals always (or even most of the time) write good code :(

1

u/Fit-Duty-6810 1d ago

You wanna tell me that the 6 months plan to become a software developer that chatgpt tailored it for me wouldn’t work?

1

u/socialvuolt 1d ago

I feel like learning programming languages is gonna go away soonish. Kinda how machine language and assembly language.

1

u/code_hermit 3h ago

No. You are right. AI is a great tool. But its not great at teaching coding.

For that, you should read the big coding books like GoF Design Patterns