Skip to content

UnSubble/CarRaceWithThreadsDemo

Repository files navigation

Semaphore Sample Project

This project is a simple Java application that demonstrates the use of Semaphores in a multithreaded environment. The program simulates vehicles moving on a screen, controlled by a Semaphore to limit concurrent access.

Table of Contents

Introduction

The Semaphore Sample Project showcases a scenario where vehicles move on a screen, and a Semaphore controls access to a limited number of resources. It's a basic illustration of how Semaphores can be used to manage concurrency in a Java application.

Usage

  1. Clone the repository.
  2. Compile and run the Main class.
  3. Watch as vehicles move on the screen, respecting the Semaphore restrictions.

Technologies Used

  • Java
  • Swing (for GUI)

License

This project is open-source and available under the MIT License.

About

A semaphore sample.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages