C++ Variable Scope

Taylor Emma
0 Min Read
Disclosure: This website may contain affiliate links, which means I may earn a commission if you click on the link and make a purchase. I only recommend products or services that I personally use and believe will add value to my readers. Your support is appreciated!

A scope is a region of the program and broadly speaking there are three places where variables can be declared:

·        Inside a function or a block which is called local variables,

·        In the definition of function parameters which is called formal parameters.

·        Outside of all functions which is called global variables.

Share This Article
A senior editor for The Mars that left the company to join the team of SenseCentral as a news editor and content creator. An artist by nature who enjoys video games, guitars, action figures, cooking, painting, drawing and good music.
Leave a review