What you’ll be able to do
By the end of this, you’ll be able to take a rough idea, something like “I want a script that renames all my files” and turn it into actual working code. Not just code that runs, but code you understand, because the AI explains it as you go. You’ll know the loop: describe, ask small, run it, hit an error, paste it back, get it fixed. That loop is basically the whole skill. Everything else is detail.
You won’t come out the other end a software engineer. But you’ll have written something real, in Python probably, and you’ll know what to do the next time something breaks. Which it will. That’s fine.
Before you start
You don’t need to know how to code. I mean that properly, not as a throwaway line. What you need is the ability to describe, clearly, what you want something to do. Input, output, that’s it. “I have a list of email addresses in a text file and I want to check which ones are valid” is a perfectly good starting point.
The tools worth knowing about: ChatGPT and Claude, which write and explain code right there in the chat window. Claude Code and Cursor, which work inside an actual project on your computer rather than a chat box. GitHub Copilot, which lives inside VS Code and suggests code as you type. And Replit, which runs code in your browser with an AI agent built in, no install needed at all.
For a first project, skip the ones that live inside a project. Go with a plain chat tool or Replit. You want somewhere to just talk and see results, not a whole development environment to learn on day one.
Python is the language to start with. It reads almost like English, the AI writes it well, and there’s a version of it or an environment to run it in wherever you land.
The bit that actually matters here isn’t the tool, it’s the conversation. A vague prompt gets you vague code. A specific one, with a clear idea of what goes in and what should come out, gets you something that works first or second try. That’s the whole trick, honestly.
Get set up
If you want zero friction, use Replit. Go to replit.com, make an account, start a new Python project (called a “repl”), and you’ve got a code editor and a place to run it, both in your browser. There’s an AI agent built in that you can just talk to directly on the same page.
If you’d rather use a tool you might already have, ChatGPT or Claude both work fine for this. Go to chatgpt.com or claude.ai, sign in or make an account, and you’re looking at a blank chat box. That’s your starting point. You’ll write the code there, copy it out, and run it somewhere else, which for a total beginner probably means Replit anyway, or a simple setup like Python installed on your own machine through python.org.
If you already use VS Code for anything, GitHub Copilot is worth knowing exists, it suggests code inline as you type rather than through a back-and-forth chat. Good once you’ve got the basics down. Not the place to start.
For this guide I’d say: pick Replit if you want everything in one place with nothing to install, or pick ChatGPT/Claude plus Python on your own computer if you’d rather learn where the code actually lives. Either is fine. Don’t overthink which one.
Try it yourself
Here’s the loop, laid out properly.
First, describe what you want, with input and output specified, and ask for the smallest version that works. Not the whole thing. The smallest thing that does anything at all.
I want a Python script that reads a text file of email addresses (one per line) and prints out only the ones that look valid. Give me the smallest version that works, nothing fancy, no extra features. Explain briefly what each part does.
Run what you get. It might just work. It might not. If it throws an error, don’t guess, don’t try to fix it yourself unless you already know how. Paste the exact error back, word for word.
I ran the code and got this error:
Traceback (most recent call last):
File "check_emails.py", line 4, in <module>
with open(filename) as f:
FileNotFoundError: [Errno 2] No such file or directory: 'emails.txt'
Before you fix it, explain what's causing this.
That last line matters. Ask it to explain before it fixes. It’s tempting to just say “fix it” and move on, but if you skip the explanation you learn nothing, and you’ll hit the same wall again next week with no idea why. Once you understand the cause, ask for the fix.
That makes sense. Please fix the code so it either creates the file if it's missing, or tells me clearly which folder it's looking in.
Then you build up from there. Add one feature at a time. Ask for the smallest addition, not five things at once.
Now add a feature that also removes duplicate email addresses before printing the results. Keep everything else the same.
That’s really it. Describe, run, error, explain, fix, repeat. Small steps. Resist the urge to ask for the finished, polished, feature-complete version on the first go. It never goes well.
Check the result
Don’t just trust that it works because it ran without an error. Running without an error and doing the right thing are two different things, and mixing them up is how bugs slip through.
Test it with normal input first. Feed your email script a file with a few obviously valid addresses and see if it says they’re valid.
Then test it on purpose with bad input. This is the step people skip and shouldn’t. Give it an empty file. Give it a file with no email addresses at all, just random text. Give it a file that doesn’t exist. See what happens. Does it crash? Does it silently do nothing? Does it give you a wrong answer with total confidence? All three are worth knowing about before you rely on this thing for anything real.
Read through the code line by line too, even if you don’t fully understand every bit of syntax. Ask the AI to talk you through it if any part’s unclear.
Can you go through this code line by line and explain what each part is doing, as if I've never seen Python before?
You’re not trying to become an expert reader of code overnight. You’re trying to get to the point where you’d notice if something looked obviously wrong, like it’s deleting files it shouldn’t be touching, or sending data somewhere you didn’t ask for.
If it doesn’t work
Two different problems tend to show up here, and they’re worth telling apart.
One is a real bug: the code does something it shouldn’t, and the fix is genuinely a fix. The other is a misunderstanding: you asked for something slightly different from what you meant, the AI did exactly what you asked, and now you need to redescribe the goal rather than debug anything. If you’ve pasted an error back three times and it’s still not working, stop and check you’re actually asking for the right thing. Sometimes the code is fine and the request was fuzzy.
AI code can be confidently wrong. It’ll write something that looks completely plausible, uses the right kind of words, has no error, and still does the wrong thing. That’s not a flaw you can code your way around, it’s just how these tools work. Read it. Run it. Test it with a bad input on purpose, like I said above. Never assume it’s correct just because it’s tidy.
And never, under any circumstances, paste API keys, passwords, or anything resembling customer data into a chat window. Not “just this once,” not with the real data swapped for fake-looking data that’s actually still real. If your script needs a password or a key to run, use a placeholder when you’re talking to the AI, and only put the real one in on your own machine, never in the conversation itself.
Keep exploring
Once you’ve got one working script under your belt, the natural next steps are putting several scripts together into something bigger, or giving whatever you’ve built a proper interface. For that, have a look at “How to get AI to build me an app” and “How to get AI to build me a website”. And if you’d rather not send any of your code or data to a chat tool at all, “How to get AI to run on my own computer” covers running these tools locally instead.
Sources and review notes
- Python documentation: https://docs.python.org/3/
- Replit docs: https://docs.replit.com/
- Claude Code docs: https://code.claude.com/docs · Cursor: https://cursor.com/
- VS Code — Copilot and agents: https://code.visualstudio.com/docs/copilot/overview
Review date: 15 September 2026 — every source above was opened and checked against the text on that date.