Replace all of the cout lines, and try it. Yes, there are function pointers in C. Quzah.
Hope is the first step on the road to disappointment.