Area Menu
C. Circle
R. Rectangle
S. Square
T. Triangle
X. eXit
Select CRSTX only
methods:
main - calls area method
area - displays the selection, accepts CRSTX input, impelements recursion
circle - calls method input for the radius, compute and display the area of the circle
rectangle - calls method input for the length and width, compute and display the area of the rectangle
square - calls method input for the side, compute and display the area of the square
triangle - calls method input for the base and height, compute and display the area of the triangle
input - validates the input value of radius, length, width, side, base, and height where the allowed value is any positive number, implements recursion for invalid value
Walang komento:
Mag-post ng isang Komento