Skip to content

mucahitkayadan/Graphs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 

Repository files navigation

Algorithms W3D3 Assignment Playground

Graph Algorithms in Java

This project demonstrates various graph algorithms implemented in Java. It includes both Depth-First Search (DFS) and Breadth-First Search (BFS) implementations, along with functionalities like checking adjacency, finding connected components, spanning tree construction, checking connectivity, and more.

Getting Started

Prerequisites

  • Java Development Kit (JDK) installed
  • Java IDE (Eclipse, IntelliJ, etc.) or a text editor for manual compilation

Running the Project

  1. Clone the repository to your local machine: git clone https://github.com/mucahitkayadan/Graphs.git. Open the project in your preferred Java IDE or compile and run it manually.
  2. Execute the Main class to run the graph algorithms and view the results.

Graph Algorithms

The project currently includes the following graph algorithms:

  • Depth-First Search (DFS)
  • Breadth-First Search (BFS)
  • Spanning Tree Construction
  • Checking Adjacency
  • Finding Connected Components
  • Checking Connectivity
  • Detecting Cycles
  • Checking if the Graph is a Tree
  • Checking if the Graph is Bipartite
  • Finding the Length of the Shortest Path

Usage

Modify the Main class to suit your specific graph and algorithm requirements. You can customize the adjacency matrix and choose between DFS and BFS by setting the useDFS flag in the main method.

// Enter 0 for DFS or 1 for BFS

Contributing

Contributions are welcome! Please fork the repository and create a pull request with your proposed changes.

License

This project is licensed under the MIT License.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages