Question: The following program, write the code in C++, please do it well, make sure you show all steps and how you did it. Please make
The following program, write the code in C++, please do it well, make sure you show all steps and how you did it. Please make the code such that I can copy paste it. Also please show the output as well, as sometimes the code is given but there is not a correct output, so show a screenshot of your output and that it matches everything asked in the question.
The following is the introduction to the assignment that is required for various tasks but you only have to do the last 2 right now. I have already done the other tasks, so I will send the main.cpp you have to fill in the code for task F and G to add the function for the main.cpp as well as having the cpp and header files for each of those 2 tasks. You have to do trapezoid.cpp/h and checkerboard3x3.cpp/h. You have to add the functions for these codes for it to run and compile. The codes for task f and g should be added to it. Please follow all these directions, and make sure all files that I have sent the code of are present and list the names of the files you have and the code for it
This is the intro to the assignment:
For this assignment, you will have to create a Makefile to build your project. It should create a single executable named main.
The main function should call all the functions that accomplish the tasks. Those functions may not be written in main.cpp but rather you should create at least one additional .cpp/.h file(s).
Write a function for each of the tasks. The functions should accept parameters for the assorted dimensions and should return a std::string with a string representing the output. Recall that you can embed a newline in a string to move to the next line.
The main function should call each task function one or more times and print out the results to show that everything works.
For example, for task A you might write a routine with a prototype std::string box(int width, int height).
You might test it from main as follows:

Note: Remember that your program should not ask for any keyboard input. When run it should clearly show that all tasks are implemented and work.
IMPORTANT: NO USER/KEYBOARD INPUT, REMEMBER THAT WHEN MAKING THE CODE
So you have to make a cpp and header file for trapezoid and checkerboard 3x3, make sure everything is defined and the code can compile and add the functions for both in main.cpp as i have commented. You should have trapezoid.cpp, trapezoid.h and same for checkerboard3x3.cpp, checkerboard3x3..h, please do it well, and make sure to add the functions for main.cpp
(as said in the comment for main.cpp I made the cpp file for the first five tasks which is the cpp file for these tasks, and then you have to make the task f and g cpp files as i wrote in comments. This is in addition to the functions you add in main.cpp as well as the header files you should make for the functions)
These are the two tasks you have to do for task f and g in which the above directions apply:


Make sure to follow above tasks as well, when ran the output of both should be similar to the example.
REMINDER NO KEYBOARD INPUT, WHEN THE CODE IS COMPILED IT SHOULD STRAIGHT OUT PRINT THE SHAPES FOR EACH OF THE TASKS, NO USER INPUT.
Please follow all directions well, make all the files and functions as asked and make sure when ran together it runs, list the name of the files and the code following it beneath when you send it. There should be the makefile that I already have, the updated main.cpp with added functions, and the cpp files for the other tasks and any additional header files needed. Follow all directions well, please.
Overall: The files you should be sending are the updated main.cpp with added functions, the trapezoid.cpp and trapezoid.h and checkerboard3x3.cpp and checkerboard3x3.h Please send the screenshot of the output as well, so i know it works and make sure the code compiles.
MAKE SURE NO USER INPUT, IT SHOULD BE HARD CODED AS WELL, AND THERE SHOULD BE THE CPP AND HEADER FILES, AS WELL AS THE FUNCTIONS ADDED TO MAIN. FOLLOW ALL DIRECTIONS WELL, AND READ EVERYTHING, URGENT.
// more code up here std::string result; result = box (3,5); std: : cout "box (3,5): "; std: :cout result std: : cout " ------------- "; // seperator // more tests to show that box works fully could be added // more code down here Task F. Upside-down trapezoid Write a program trapezoid.cpp that prints an upside-down trapezoid of given width and height . However, if the input height is impossibly large for the given width, then the program should report, Impossible shape! Example 1: Input width: 12 Input height: 5 Shape: Example 2: Input width: 12 Input height: 7 Impossible shape! Hint: You can start with the number of spaces=0;stars=width; On each line, print that number of spaces followed by that number of stars. After that, the number of spaces gets incremented by 1 , while the number of stars gets decremented by 2 : spaces+=1;stars=2; Task G. Checkerboard (33) Write a program checkerboard 33.cpp that asks the user to input width and height and prints a checkerboard of 3-by-3 squares. (It should work even if the input dimensions are not a multiple of three.) Example 1: Inputwidth:16Inputheight:11 Example 2: Input width: 27 Input height: 27
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
