Yes, I should correct myself, variables can be declared in a header file, as long as they are not defined there (you mean defined, not initialized – a variable need not be initialized even though its good practice).

To quote K&R:
Declarations specify the interpretation given to each identifier – they do not necessarily reserve storage associated with that identifier. Declarations that reserve storage are called definitions.

An example of a declaration that does not reserve storage:
extern int x;

So the title of my post should be “Defining variables in header files”