Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 1

a and b in this program are called global variables.

At first glance
use of global variables seems easier than passing arguments around.
Why not have all the data declared outside of functions, so that all
functions can access what they want when they want? But this apparent
convenience causes many problems when writing larger systems.
Since a global variable can be seen, accessed and changed by any

You might also like