int is 4 bytes, char is 1 byte. Why, then, at the very bottom of the program, 12 is displayed instead of 9?
class A { public: A() {} ~A() {} void f_a(); private: int var_a; }; class B : public A { public: B() {} ~B() {} void f_b(); private: int var_b; }; class C : public B { public: C() {} ~C() {} void f_c(); private: char var_c; }; int main() { A objA; B objB; C objC; cout << sizeof(objA) << endl; // выводит 4 cout << sizeof(objB) << endl; // выводит 8 cout << sizeof(objC) << endl; // выводит 12??? почему ни 9? return 0; }