I\'m sure there\'s a very easy explanation for this. What is the difference between this:
function barber($type){ echo \"You wanted a $type haircut, no
in your first example you're using function name which is a string. it might come from outside or be determined on the fly. that is, you don't know what function will need to be run at the moment of the code creation.