Question: Make sure its C++, please! thank you Problem 2. Comprehensive programming: (file I/O, if...else, for loop, output manipulators) Cheap Chirps is a pet store specializing
Problem 2. Comprehensive programming: (file I/O, if...else, for loop, output manipulators) Cheap Chirps is a pet store specializing in pet birds. The store needs a new inventory program and has hired you to develop the program. Write a C++ program that will: 1. Read an inventory list of birds from a data file called BIRD txt. The file contains information on bird species in the store. There are four lines in the file. Each line of the file has type of bird (no larger than 20 characters), price of the bird, and the consumed food in pounds monthly. Use for loop to read the related information. BIRD txt MACAW 2,500.00 20 AMAZON 550.7515 COCKATIEL 123.502 PARAKEET 45.501 2. Your program will find if the bird is a large hookbill or a small hookbill (Large hookbills eat 15 or more pounds of food a month.) Use a character 'L' to represent a large hookbill and an ' S ' to represent a small hookbill. 3. Your program will also calculate the average price of a bird and the average amount of food eaten in one month. 4. Print the output so that it is organized as below. Note the values for the averages are printed to two decimal places. All printing is done in the main function
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
