CC User Functions
Creating blocks of code.
C User Functions
A function is a block of code which only runs when it is called.
You can pass data, known as parameters, into a function.
Functions are used to perform certain actions, and they are important for reusing code: Define the code once, and use it many times.
Create a Function
To create (often referred to as declare) a function, specify the name of the function, followed by parenthesis ():
void myFunction() {
// code to be executed
}
Examples
Call a Function
c example