Answered step by step
Verified Expert Solution
Question
1 Approved Answer
2.15.3: Strings. Read the string variables myCity and myState from input, assuming that both the city and state are single words. Ex: If the input
2.15.3: Strings.
Read the string variables myCity and myState from input, assuming that both the city and state are single words.
Ex: If the input is Helena Montana, then the output is:
(How do I get the correct output shown below since I can't edit lines 1 -7 and 13-16)
Ex: If the input is Helena Montana, then the output is: I am from Helena, Montana. Since the city and state are assumed to be single words, cin is used to read the string variables myCity and myState from input Not all tests passed. 1: Compare output Output is nearly correct, but whitespace differs. See highlights below. Input Your output I am from Helena, Expected output
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started