(C code) Heap code that can insert and remove from a source text