0Pricing
Javascript for Kids · Lesson

Write Your Own Algorithm

Make your own step-by-step plan, like a recipe.

Write Your Own Algorithm is a free Javascript for Kids lesson on CoddyKit — lesson 4 of 4. You can read the complete lesson below for free — then practise it hands-on in the browser with a built-in code editor and a 24/7 AI tutor. It is part of the Javascript for Kids learning path, one of 4 lessons in the course, and your progress syncs across the web and the CoddyKit app.

Be the Author! ✍️

Hi, amazing coder! 👋🌟

Today YOU make your very own algorithm! 🎉

Remember, an algorithm is just a step-by-step plan, like a recipe. 📋🍪

Let's write one together! ✍️

Pick a Job 🎯

First, choose something you want to do. 🤔

It can be anything! For example:

  • Make a peanut butter sandwich 🥪
  • Brush your teeth 🪥
  • Build a block tower 🧱

Let's plan a sandwich together! 😋

Think of the Steps 🧠

Now think: what do you do FIRST? 1️⃣

Then what's NEXT? 2️⃣

Keep going until the job is done! 3️⃣4️⃣

Picture it in your head like a little movie! 🎬

Our Sandwich Plan 🥪

Here's our sandwich algorithm! 🎉

  • Step 1: Get two slices of bread 🍞
  • Step 2: Spread peanut butter 🥜
  • Step 3: Spread jam 🍓
  • Step 4: Put the slices together 🥪
  • Step 5: Take a yummy bite! 😋

Tiny Steps Are Better 🐜

Make each step small and clear. 🔍

Don't say "make the sandwich" — that's too big! 🤔

Break it into little steps the robot can follow. 🤖

Tiny steps = a happy plan! 🐜

Check the Order 🪜

Now read your steps from top to bottom. 👀

Are they in the right order? 🪜

You can't eat the sandwich before you make it! 😂

Fix any mixed-up steps. ✅

Test It Like a Robot 🤖

Now pretend YOU are the robot. 🦾

Follow your own steps one by one. 👣

Did anything go wrong? Did you miss a step? 🔍

Testing helps you make it perfect! 🌟

Your Turn: Brush Teeth 🪥

Now try one yourself in your head! 🧠

Make an algorithm for brushing your teeth: 🦷

  • What's step 1? 1️⃣
  • What's step 2? 2️⃣
  • What's the last step? ✨

You can do it! 💪

A Tower Plan 🧱

Here's a block tower algorithm! 🏰

  • Step 1: Get your blocks 🧱
  • Step 2: Place one block down ⬜
  • Step 3: Stack another on top ⬜
  • Step 4: Keep stacking! 🔼
  • Step 5: Cheer for your tower! 🎉

You're an Algorithm Writer! ✍️

Wow! You just wrote algorithms! 🤩

You picked a job, made tiny steps, put them in order, and tested them! ✅

That is EXACTLY what real coders do! 🦸

You're incredible! 🌟

The Coder Recipe 🍳

Remember the coder recipe for any algorithm: 📋

  • Pick a job 🎯
  • Break it into tiny steps 🐜
  • Put steps in order 🪜
  • Test it like a robot 🤖

Now you have it forever! 💛

Quick Check

One last fun question! You've got this! 😊

You Did It, Coder! 🏆

Hooray! 🥳 You finished the whole course! Today you learned:

  • How to write your OWN algorithm ✍️
  • Use tiny steps in the right order 🪜
  • Test it like a robot 🤖

You think like a coder now! 🦸 Next, unlock your Coder Superpowers! ⚡ See you there! 👋

Frequently asked questions

Is the “Write Your Own Algorithm” lesson free?

Yes — the full text of “Write Your Own Algorithm” is free to read here on the web, and the Javascript for Kids course includes 4 lessons in total. To practise it interactively (a built-in code editor and a 24/7 AI tutor) and unlock the rest of the Javascript for Kids course, upgrade to CoddyKit PRO.

What will I learn in “Write Your Own Algorithm”?

Make your own step-by-step plan, like a recipe. You practise Javascript for Kids with hands-on code you run directly in the browser, and a 24/7 AI tutor answers your questions as you work through the lesson.

Do I need any experience to start Javascript for Kids?

No prior experience is required. Javascript for Kids on CoddyKit is structured for beginners through advanced learners; this is — lesson 4 of 4, so you can start here or from the beginning and move at your own pace.

How long does the “Write Your Own Algorithm” lesson take?

Most CoddyKit lessons take about 5–10 minutes. Each one is bite-sized and interactive, so you make steady progress and pick up exactly where you left off across the web and the app.

Can I write and run code in this Javascript for Kids lesson?

Yes. Every Javascript for Kids lesson includes a built-in code editor, so you write and run real code right in your browser and get instant AI feedback — no local setup required.

All lessons in this course

  1. What Is an Algorithm?
  2. Why Order Matters
  3. Be a Robot!
  4. Write Your Own Algorithm
← Back to Javascript for Kids