Question: I'm not sure why the source code is not working, so many videos show the same way, I need to print out the length of

I'm not sure why the source code is not working, so many videos show the same way, I need to print out the length of the string and the first, middle initial and last name.

#include #include

using std::cin; using std::string; using std::endl; using std::cout; using namespace std;

string full_name (string first, char middle, string last) { return first +" "+middle+"."+last; }

int main() { cout << "Please enter your first name, middle initial, and last name: "; string first,last; char middle; cin >> first, middle, last; cout << full_name.length() << endl; cout << full_name(first,middle,last) << endl; return 0; }

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!