Learn
Well done! Functions are a fundamental concept in programming, and learning the basics will serve you wherever your path leads, regardless of language or domain. To review:
- A function is a sequence of instructions that performs a specific task, packaged as a unit.
- When we define a function, we specify the instructions, inputs, and name of the function.
- When we call a function, all of its instructions are executed.
- Functions can be executed many times, making its instructions reusable.
- Functions can have parameters, which accept input values, making its instructions flexible.
- Functions organize a program into distinct units, making interchanging and editing them easier. This makes your entire program organized and modular.
Instructions
Make sure you’re comfortable with the above concepts before moving on!
Take this course for free
By signing up for Codecademy, you agree to Codecademy's Terms of Service & Privacy Policy.