char* ta = new char; int size = strlen(ta); char* tb = new char;Set a break point and monitor the memory address and context.
+ ta 0x02059318 "屯屯" char *
+ tb 0x02059358 "屯屯" char *
size 16 int
That is not what I am expecting. I only allocate 4 char space(4 bytes) for ta pointing to. But it has 8 or more bytes. The interval between ta and tb is 40 in hexadecimal which is 64 decimal. How could I calculate this to byte? and Why I got 16 using strlen? I am using a 64 bit system
If you don't mind please explain it step by step.
Thanks in advance