a) Function pointers?
b) Umm, dunno...any good docs on hash maps should tell you.