Explain create, read, update, and delete operations by mapping each to a specific app idea, a real-world trigger, a code example, and its HTTP method.
You are an instructor who refuses to explain CRUD as four letters standing for four verbs in the abstract, because the acronym only actually clicks once it is mapped onto a specific thing being managed, tasks in a to-do app, books in a library tracker, and each operation gets tied to the real user action that would trigger it. My app idea is [APP_IDEA], described in plain English, such as a to-do list app, a book library tracker, or a simple contacts manager, and my code example should be in [LANGUAGE:select:Python,JavaScript,Java,C++]. If I left [APP_IDEA] blank, ask me to describe one before doing anything else instead of inventing an app to explain. First, name the core "thing" my app idea is actually managing, a Task, a Book, a Contact, and describe its basic shape, the handful of fields it would realistically need, such as a title, a status, and a due date for a Task. Then walk through create, read, update, and delete one at a time, and for each operation, state the real-world user action that triggers it, such as clicking "Add Task" for create or clicking a trash icon next to an item for delete, provide a short code example in [LANGUAGE] performing that operation against a simple in-memory list of items, since a full database setup is a separate topic, with comments in plain language explaining what each line does, and name the HTTP method that operation conventionally maps to in a real web application, `POST` for create, `GET` for read, `PUT` or `PATCH` for update, and `DELETE` for delete, stating briefly why that specific method was chosen for that operation by convention. For the read operation specifically, distinguish between reading a single specific item, such as viewing one task's details, and reading a full list of items, such as viewing the whole to-do list, since these are both "read" in CRUD terms but usually need separate code and separate real-world triggers. Close by asking whether I want to see these same four operations connected end to end in a short realistic sequence, such as creating a task, reading the list to confirm it appears, updating its status, then deleting it, so I can see the full lifecycle of one piece of data rather than four isolated examples that never interact.
Use this prompt anywhere
10,000+ expert prompts for ChatGPT, Claude, Gemini, and wherever you use AI.
Get Early AccessDiscover more prompts that could help with your workflow.
Build a small working program that calls a real public API, with the request, response, and API key setup explained step by step.
Explain a core functional programming idea, such as pure functions or immutability, with a broken code example and its fixed version shown side by side.
Explain a built-in math function, square root, power, absolute value, or rounding, covering math and syntax, then generate practice calls to predict before revealing results.
10,000+ expert-curated prompts for ChatGPT, Claude, Gemini, and wherever you use AI. Our extension helps any prompt deliver better results.