Pointer arithmetic for structs
问题 Given a struct definition that contains one double and three int variables (4 variables in all), if p is a pointer to this struct with a value 0x1000, what value does p++ have? This is not a homework problem, so don't worry. I'm just trying to prepare for a test and I can't figure out this practice problem. Thanks This is in C. Yes I want the value of p after it is incremented. This is a 32-bit machine 回答1: struct foobar *p; p = 0x1000; p++; is the same as struct foobar *p; p = 0x1000 +