Please send questions to
st10@humboldt.edu .
/*--------------------------------------------------
created by smtuttle at Tue Apr 27 21:33:02 PDT 2010
--------------------------------------------------*/
#include <iostream>
#include <cmath>
using namespace std;
/*--------------------------------------------------
Contract: get_full_names : string string string& string& -> void
Purpose: expects a first name and a last name, and also has two string
output parameters; it does not return anything, but the first
output parameter is set to the full name for that name,
last-name-first (with a comma and blank in between), and the
second output parameter is set to the full name for that name,
first-name-first (with a blank in between)
Examples:
string last_first;
string first_last;
get_name_combos("Charles", "Schulz", last_first, first_last);
after this call:
last_first == "Schulz, Charles"
first_last == "Charles Schulz"
--------------------------------------------------*/
void get_full_names(string first_name, string last_name,
string& last_then_first, string& first_then_last)
{
last_then_first = last_name + ", " + first_name;
first_then_last = first_name + " " + last_name;
}