C++ Function Definition Add a Function Prototype before main()
function
#include <iostream> using namespace std; void printName(string first, string last); int main() /*from w w w.j a v a 2 s. c om*/ { printName("a", "b"); return 0; } void printName(string first, string last) { string fullname = first + " " + last; cout << fullname << endl; }