Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Please help me with that. Thanks Write a C++ program that will 1. Declare two vectors a. One of integer b. One of float or
Please help me with that. Thanks
Write a C++ program that will 1. Declare two vectors a. One of integer b. One of float or double 2. Using a loop, prompt the user to input the quantity and cost of eight items. a. Quantity should be stored in the integer vector and cost should be stored in the float or double vector 3. Within a function, a. Print the quantity, cost and total cost of items on hand (total cost of items must be calculated), for each of the items entered in the vectors. (Ex Looking at the first line of output, if quantity is 3 and cost is 10.12, the output should appear as follows: Onty Cost 10.12 18.28 Total 30.36 18.28 1 NOTE: All dollar amounts should be displayed with two decimal placesStep 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