How do you use AI like ChatGPT to solve programming problems?

Since I’m new to Python I have it write me small snippets of code if I cannot figure it out myself. Since I learn best by looking at code and having it explained, occasionally people think I’m doing homework when I’m not.

I have used Google Gemini AI to write a short Python program to look for multiple strings on a line in any order and print that line.

I have not used it to write any long programs.

However I don’t see any use to AI when trying to integrate my Python programs with the Azure Function Apps since the Python code is a small part of it .The Azure Function has to be set up via several screens and a few steps which I don’t see how AI could reproduce.

Also the AI gets it’s info from other web pages, and because Azure screens and features change so fast, any web page or tutorial older than 6 months probably won’t work (which has been my experience.)

Letting an AI write your code is basically equivalent to searching the web for solutions and copying and pasting whichever ones you find and calling that a program. You have all the normal problems of copying code from the internet (that it might be buggy, malicious, copyrighted, or functional but just bad), plus the added problem that it’s being combined by something that has no idea what it’s doing, and is just really good at sounding plausible.

So, how do I use ChatGPT to solve programming problems?

I don’t.

It’s that simple.


I was trying to come up with a SQL query (I don’t know anything about SQL so it wasn’t going well) and I asked Copilot for help. The code it gave me flat-out didn’t work, but I was able to merge that with what I had already written and get a functioning result. The logic of what it returned was mostly sound, but the syntax was flat-out broken in a way I wouldn’t have been able to fix without having already done some reading. I would definitely not just trust anything AI-generated without going over it with a fine-toothed comb, so while it might provide inspiration, you still have to read and understand it, or you’re just setting yourself up for problems later.