Graph

package
v0.0.0-...-bd5f7e2 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Graph

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

func Constructor

func Constructor(n int, edges [][]int) Graph

func (*Graph) AddEdge

func (g *Graph) AddEdge(edge []int)

func (*Graph) ShortestPath

func (g *Graph) ShortestPath(node1 int, node2 int) int

type PriorityQueue

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

func (*PriorityQueue) Len

func (piq *PriorityQueue) Len() int

func (*PriorityQueue) Less

func (piq *PriorityQueue) Less(i, j int) bool

func (*PriorityQueue) Pop

func (piq *PriorityQueue) Pop() any

func (*PriorityQueue) Push

func (piq *PriorityQueue) Push(x any)

func (*PriorityQueue) Swap

func (piq *PriorityQueue) Swap(i, j int)

Jump to

Keyboard shortcuts

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