#include<iostream>
using namespace std;
class phone{
char a;
int c;
char b;
};
int main(void)
{
phone obj;
cout<<sizeof(obj);
}
Why the output is 12 instead of 8??? I'm using a 64-bit machine and GCC 4.9.2 64-bit release.
#include<iostream>
using namespace std;
class phone{
char a;
int c;
char b;
};
int main(void)
{
phone obj;
cout<<sizeof(obj);
}
Why the output is 12 instead of 8??? I'm using a 64-bit machine and GCC 4.9.2 64-bit release.