< Previous | Contents | Next >

Declaring Global Variables

You declare global variables outside of any function in your program file. Thats what I do in the following line, which creates a global variable named glob initialized to 10.

int glob = 10; // global variable