...

/

Write Your Own Commands (Functions)

Write Your Own Commands (Functions)

Declare and call functions to structure programs.

You’ve written code that runs from top to bottom. Now let’s break it into reusable chunks called functions. They help organize, repeat, and simplify your code.

Functions can take input(s), perform specific operations (processing), and then return an output or perform a task. This flow allows you to reuse the same logic with different inputs, making your code more efficient and easier to maintain.

Press + to interact
What a function does
What a function does

Goal

...