Create a series of small programs each performing a calculation. Name each program the shape, followed by “-“, followed by the type of calculations (examples triangle-area.py, rectangularprism-volume.py). Each program should first display a message stating what the program does. This can reduce confusion if the student runs the wrong program.
For each variable in the equation ask the user to enter a value. Since these are students don’t just give them just the variable letter (like r); tell them the name of the variable also (like radius). If a variable appears many times in an equation only ask the user once for it.
Your programs need to perform the correct calculation and output the correct equation and the answer.
Here is some sample runs.
Assume user runs square-area.py
This program will compute the area of a square.
Enter the length of one of the sides of the square (a)?
The equation for the area of a square is (area = a^2).
Your square has an area of 9
Assume user runs squarepyramid-volume.py
This program will compute the volume of a square pyramid.
Enter the area of the base of the pyramid (B)?
Enter the height of the pyramid (h)?
The equation for the volume of a square pyramid is (volume = 1/3 * B * h).
Your square has an area of 3.33333333
Write a small program for each of the shape and type of equations.
Rectangular prism Volume
Right circular cylinder Volume
Square pyramid Volume
Right circular cone Volume
These solutions may offer step-by-step problem-solving explanations or good writing examples that include modern styles of formatting and construction of bibliographies out of text citations and references. Students may use these solutions for personal skill-building and practice. Unethical use is strictly forbidden.# square-area.py
print("This program will comopute the area a square.")
w = input("Enter the length of width/height of the square (w)? ")
w = float(w)
print("The equation for the area of a square is \n area = w*w. ")
print("Your square has a area of " + str(w*w))...
By purchasing this solution you'll be able to access the following files:
Solution.docx and Solution.zip.