Master function declaration, definition, call by value semantics, stack frames, calling conventions, and recursion to write efficient, modular C code.
A reusable block of code that performs a specific task. Functions organize code into logical units.
main(), where execution begins.
The blueprint versus the implementation.
Tells the compiler about a function before it's used. Includes name, return type, and parameters.
The actual implementation containing the code to execute.
C passes copies of arguments, not originals. Changes inside functions don't affect the caller.
Exiting a function and sending data back to the caller.
Returns a result to the caller.
Returns nothing.
How memory manages function calls. Every call creates a "Stack Frame".
How the CPU passes data between functions at the machine level.
First 6 integer args go into registers:
Where the result goes:
A function calling itself. Requires a Base Case to stop.