Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1 . 1 2 C + + example: Married - couple names zyDE 1 . 1 2 . 1 : Married - couple names. Pat

1.12 C++ example: Married-couple names
zyDE 1.12.1: Married-couple names.
Pat Smith and Kelly Jones are engaged. What are possible last name combinations for the married couple (listing Pat first)?
Run the program below to see three possible married-couple names.
Extend the program to print the two hyphenated last name options (Smith-Jones, and Jones-Smith). Run the program agair
Load default template...
cout "What is the second person's first name?" endl;
cin firstName2;
cout "What is the second person's last name?" endl;
cin lastName2;
cout "Here are some common married-couple names:" endl;
cout firstName1" and " firstName2"" lastName1 endl;
cout firstName1" and " firstName2"" lastName2 endl;
// FIXME: Print two hyphenated last name options, with either last name
I/ appearing first. (A hyphen can be written as "-")
return ;
}
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Understanding Oracle APEX 5 Application Development

Authors: Edward Sciore

2nd Edition

1484209893, 9781484209899