How does function overloading work at run-time, and why overload?
问题 Let's say I have a class named ClothingStore. That class has 3 member functions, that point a visitor to the right department of the store. Member functions are ChildrenDept, MenDept and WomenDept, depending on whether the visitor is a child, a man or a woman. Function overloading can be used to make 3 functions that have same name, say, PointToDept, but take different input argument ( child, man, woman ). What is actually happening on run-time when program is executing ? My guess is that