Functions

<aside> 1️⃣ Subroutines that return a value

</aside>

Procedures

<aside> 1️⃣ Subroutines that don’t return a value

</aside>

Recursion

<aside> 🔁 A recursive function is one that calls itself until a base case is met.

</aside>

When are non-recursive algorithms better?

Methods of passing

By reference

<aside> 💡 When the address is passed, rather than the actual data

</aside>

✅  Avoids the larger amount of processing and storage associated with creating copies of the data, and allows desirable changes to be passed back into the main program

By value