> Where would you declare a local variable for a class?
If it is an instance variable (one for each object instance), it has to be declared in the class as a non static member.
If it is a shared variable (common to all object instances),
either declare it as a static member of the class (and define it in the implementation file)
or define it as a non member with internal linkage in the implementation file.
1 2 3 4 5 6 7 8 9
unsignedint number ; // instance variable
// each instance of account has its own number,
// different accounts have different numbers.
staticconstdouble rate_of_interest ; // static variable
// all instances of account share a common rate of interest.