Metadata-Version: 2.1
Name: graph-dfs
Version: 0.0.6
Summary: Graphs and Depth First Search
Home-page: https://github.com/daniel-ufabc/graph-dfs
License: MIT
Keywords: graph,DFS
Author: Daniel M. Martin
Author-email: danielmmartin@gmail.com
Requires-Python: >=3.7,<4.0
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Topic :: Software Development :: Libraries
Project-URL: Repository, https://github.com/daniel-ufabc/graph-dfs
Description-Content-Type: text/markdown

# Graph-DFS

This package allows for the creation of graphs. It also provides the depth first search algorithm.

## Installation

```shell
pip install graph-dfs
```

## How to use it?

To create a graph, do:

```python
g = Graph(n)
```

where `n` is the number of vertices. To create an arc from
vertex `a` to vertex `b`, do:

```python
g.link(a, b)
```

where `a` and `b` are indices in the range `[0, n - 1]`. You can perform a depth first search on the graph
with:

```python
dfs = DFS(g)
dfs.start()
```

If you desire to obtain a topological sorting of the graph, then do so after a DFS with:

```python
dfs.opological_sorting()
```

