Question: In C++ Write a program that declares two variables: a string firstName and int age. Write a function, called getName, that when called, prompts the

In C++ Write a program that declares two variables: a string firstNameIn C++

Write a program that declares two variables: a string firstName and int age. Write a function, called getName, that when called, prompts the user for their first name. The function should return the first name and store it in the firstName variable. Write a function, called getAge, that when called, prompts the user for their age. The function should return the age and store it in the age variable. Write a function, that uses the firstName and age as arguments. In the function, print out the person's name and age

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!