Skip to content

Alwin24/parkinglot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Parking Lot System

Implementing parking lot system in Java, using object-oriented principles.

Additional Assumptions

  • Compact spots and regular spots are subsections of car spots.
  • A van can park in a single van spot or 3 regular spots.

Features

  • Parking spots for motorcycles, cars, and vans.
  • Different types of parking spots for compact cars, regular cars, and vans.
  • Methods to check remaining spots, total spots, and occupancy status.
  • Support for parking and checking the occupancy of specific vehicle types.

Class Structure

  • ParkingSpot.java: Represents a parking spot.
  • ParkingLot.java: Manages the parking lot and parking spots.
  • VehicleType.java: Enum representing types of vehicles.

Usage

To run the provided example:

  1. Compile the Java files:

    cd parkinglot
    javac *.java
  2. Run the main class:

    java Main

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages