Tested in VS2005 (using %p instead of %d), the output is 004030DC 004030D8 00000001 004030C8.

So it bothers you that ptr-p=1, but not that ptr++ increments ptr by 4?

Pointer arithmetic doesn't work the same way as integer arithmetic. Pointer arithmetic takes into account what is being pointed at. So the compiler knows that both ptr and p are pointers, so ++ will increase ptr by the size of a pointer (4 bytes for me, and presumably 2 bytes for you because you're using a 16-bit compiler), and ptr-p works out the difference in sizeof(pointer) chunks between ptr and p, which is 1.