Question
31) The investment company of Pickum & Loozem has been recording the trading price of a particular stock over a 15-day period. Write a program
31) The investment company of Pickum & Loozem has been recording the trading price of a particular stock over a 15-day period. Write a program that reads these prices and stores them in a sequential container and then sorts them into increasing order. The program should find and display a. The trading range (the lowest and the highest prices recorded). b. A sequence that shows how much the price rose or fell each day
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------.
Adapted from Page 583, Problem #31
This assignment is designed to ascertain that you understand the Standard Template Library, and the appropriate use of standard containers and standard algorithms found in that library.
The investment company of Pickem & Loozem has been recording the trading price of one particular stock over a fifteen day period. Write a program that:
1. queries the user for these prices and stores them in a sequential standard container. Keep in mind that stock prices are recorded in dollars and cents.
2. Finds and displays the following - all calculations must use standard algorithms
a. the lowest price
b. the highest price
c. a sequence (stored in a standard container) showing the daily changes in prices (how much the stock price rose or fell each day)
3. Sort and display the stock prices from lowest to highest using a standard algorithm.
THE PROGRAM ASSIGNMENT IS BASED ON ABOVE GIVEN QUESTION 31
NEED THE PROGRAM TO BE WRITTEN IN C++ WITH COMPLETE DOCUMENTATION
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