add code snippet to mimic STL:map in C