Skip to content

Latest commit

 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 

Repository files navigation

Java-Assigment-5

Shape Calculator

Overview

This Java program calculates the area, perimeter, surface area, and volume of various shapes such as Circle, Rectangle, Square, Sphere, Cylinder, and Pyramid. It presents a menu-driven interface allowing users to choose the shape they want to calculate properties for.

Description

The program consists of a Main class that contains the main menu-driven logic to interact with the shapes. Each shape is represented by a separate class (Circle, Rectangle, Square, Sphere, Cylinder, and Pyramid). Each shape class has methods to calculate its area, perimeter, surface area, and volume. The program uses a loop to repeatedly display the menu until the user chooses to exit.

Usage

  1. Run the Main.java file.
  2. Follow the menu prompts to select the shape for which you want to calculate properties.
  3. Enter the required dimensions when prompted.
  4. The program will display the calculated area, perimeter, surface area, and volume of the selected shape.
  5. Choose option 7 to exit the program.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors