Question: Exercise A: (Personal Information) Refer to Week-1 Assignment, Exercise A, Personal Information. This time, ask the user to enter their first name, last name, age,
Exercise A: (Personal Information)
Refer to Week-1 Assignment, Exercise A, Personal Information.
This time, ask the user to enter their first name, last name, age, salary, and bonus.
Note:
- In this exercise, pay attention to the data type.
- Age can't be in decimal. Must pick the data type as an int data type for age.
- Salary and bonus can be in decimal. Make sure, your code should be able to handle numbers entered by the user in decimal.
- When you add a salary and bonus, the final output may be in decimal. Your code should be able to handle them.
- You must add the line gap in the output if there is a line gap in the output.
- Don't do any calculations manually. Your program should be able to handle the sum of 2 numbers.
I am attaching the expected output with this exercise. You must match your output with mine.

Hint: Please pay attention to Section 3.8 (Working with characters and String Objects) about how to use getline() function.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
