// File: over2.cpp // // Simple case of function overloading #include using namespace std ; void PrintMe (string s) { cout << "string s = \"" << s << "\"" << endl ; } void PrintMe (int i) { cout << "int i = " << i << endl ; } void PrintMe (string s, int i) { cout << s << " " << i << endl ; } int main() { string name = "Yellow Pig" ; int n = 17 ; float f = 3.14 ; PrintMe(name) ; PrintMe(n) ; PrintMe(name, n) ; }