algorithms

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 11, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Node

type Node struct {
	// contains filtered or unexported fields
}

func NewNode

func NewNode() *Node

func (*Node) AddDirectedEdge

func (n *Node) AddDirectedEdge(other *Node, distance int)

func (*Node) AddUndirectedEdge

func (n *Node) AddUndirectedEdge(other *Node, distance int)

type Path

type Path struct {
	// contains filtered or unexported fields
}

func ShortestPath

func ShortestPath(from, to *Node) *Path

func (*Path) TotalDistance

func (p *Path) TotalDistance() int

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL