Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ManhattanDistance ¶
ManhattanDistance returns the manhattan distance between two points (delta between x's plus delta between y's)
Types ¶
type File ¶
type File []byte
File is a file as bytearray
func (File) WithOSLinebreaks ¶
WithOSLinebreaks returns the File with OS-specific linebreaks instead of LF (for testing purposes)
type Line ¶
type Line string
Line is a string
func (Line) SubSplitWith ¶
SubSplitWith splits a Line on into Lines using the given separator
type Lines ¶
type Lines []Line
Lines is an array of Line
type Point ¶
type Point struct {
X, Y int
}
func (*Point) Neighbours ¶
Neighbours returns direct neighbours on x and y axis (no diagonal neighbours)
func (*Point) NeighboursWithDiagonal ¶
Neighbours returns direct neighbours on x and y axis as well as diagonal neighbours
Click to show internal directories.
Click to hide internal directories.