void *sbrk(int n); // prototype for sbrk
char *p,*q; // two pointers for allocated
blocks
p = (char *)sbrk(100); // allocate a 100-byte block
q = (char *)sbrk(200); // allocate a 200-byte block
sbrk(-200); // free the 200-byte block
sbrk(-100); // free the 100-byte block