C++ for Complete Beginners 27 - Function Parameters: Passing Data to Subroutines

We can pass data to functions if necessary. You can make your function configurable via "parameters"; you can then supply values for these parameters where you use your function; the values you supply are known as "arguments". This language is borrowed from mathematics, and although C++ functions don't conform to the strict idea of a mathematical function, it's often convenient to think of C++ functions as "black boxes" that takes in some data, process it and spit out some new data.



Click here to download source code for this tutorial.