Zero-Code AI App BuilderZero-Code AI App Builder
Prompting & Planning

Prompt engineering

Get the answer you want, the first time

You already know how to chat with AI. Now you'll learn to write prompts that get great answers on purpose, not by luck.

What is prompt engineering?

Imagine ordering a cake. If you say "make me a cake", you might get anything. If you say "a small chocolate cake for 6 people, no nuts, ready Friday", you get what you need.

Prompt engineering is the same idea. It means writing your request so the AI knows exactly what to do. You don't need any code. You only need clear words.

The 5-part framework

Most great prompts have the same five parts. You won't always need all five, but checking each one makes your prompts much stronger.

  • Role — who the AI should act as ("You are a friendly study coach").
  • Context — the background it needs ("I'm a beginner with exams in 3 weeks").
  • Task — the exact job, with a clear verb ("Create a study plan").
  • Constraints — the limits ("Max 2 hours per day, weekends off").
  • Output — the shape of the answer ("Show it as a table").
Role
who the AI is
→
Context
what it knows
→
Task
what to do
→
Constraints
the limits
→
Output
the format
The five parts of a strong prompt, in the order you usually write them.

Here is a prompt that uses all five parts:

Prompt
You are a friendly study coach for beginners.
I have a biology exam in 3 weeks and I'm behind on 4 chapters.
Create a day-by-day study plan for me.
Keep it to 2 hours per day and leave Sundays free.
Show the plan as a table with columns: Day, Chapter, Activity, Time.

What you'll learn

How to use this section

The first two pages cover the 5-part framework. The next four cover advanced skills you'll use every day when building apps. I recommend going in order. Every page follows the same format:

  1. What is it? — A simple explanation with an everyday example
  2. See it in action — Prompts you can copy and try
  3. Common mistakes — Weak prompts next to better ones
  4. Practice — A few quick questions to check your understanding
Keep ChatGPT, Claude, or Gemini open in another tab. Paste each example prompt, then change one part and see how the answer changes. That is the fastest way to learn.

Practice

Try these exercises to lock in what you just learned.

Quiz
Not started
Which list shows the five parts of the prompt framework used in this course?

What's next?

Let's start with the first two parts of every strong prompt: giving the AI a role and the right context.