Skip to content

This repository contains Java implementations of Breadth-First Search (BFS) and Depth-First Search (DFS) algorithms.

Notifications You must be signed in to change notification settings

samyam81/Search

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

Search

This repository contains implementations of various search algorithms in Java.

Overview

The repository includes implementations of Breadth-First Search (BFS) and Depth-First Search (DFS) algorithms in Java.

BFS Implementation

The BFS algorithm is implemented in the BFStree class. It provides a method bfsOfGraph(int V, ArrayList<ArrayList<Integer>> adj) that returns an ArrayList containing the vertices visited in BFS order.

DFS Implementation

The DFS algorithm is implemented in the DFS1 class. It uses an adjacency matrix representation of the graph and provides functionality for performing the DFS traversal.

Usage

To use the implementations in this repository:

  1. Clone the repository to your local machine.
  2. Use the provided classes in your Java projects.
  3. Follow the respective usage instructions for BFS and DFS implementations.

Contributors

  • Samyam.81

About

This repository contains Java implementations of Breadth-First Search (BFS) and Depth-First Search (DFS) algorithms.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages