The parameter list is the normal means to supply values to a function. Global variables are an alternate means for a function to have access to values. Describe what a global variable is, how it is declared, and then discuss the pros and cons of combining global variables and functions.© BrainMass Inc. brainmass.com July 17, 2018, 4:11 am ad1c9bdddf
Global variables are the variables that has the global scope i.e. they can be accessed from any function that the program comprises. These variables are declared outside all the function definitions including the main() function and are accessible from the place of declaration till the end of the program. And any changes made to these variables remain consistent ...
The expert describes what a global variable is, how it is declared, and then discuss the pros and cons of combining global variables and functions.