O'Reilly logo
  • terrer karthi thinks this is interesting:

nt and Offset Address

Every address has two parts, segment and offset. We can separate these address parts using following two macros defined in dos.h header file.

FP_SEG( ) – This macro is used to obtain segment address of the given pointer variable.

FP_OFF ( ) – This macro is used to obtain offset address of the given pointer variable.

The following program illustrates working of both these macros.

11.1 Write a program to obtain segment and offset address.

# include <...