2022 Day 23 Complete
This commit is contained in:
@@ -66,6 +66,13 @@ func (c *Coordinate) SE() Coordinate {
|
||||
func (c *Coordinate) GetOrthNeighbors() []Coordinate {
|
||||
return []Coordinate{c.North(), c.East(), c.South(), c.West()}
|
||||
}
|
||||
func (c *Coordinate) GetAllNeighbors() []Coordinate {
|
||||
return []Coordinate{
|
||||
c.North(), c.NE(),
|
||||
c.East(), c.SE(),
|
||||
c.South(), c.SW(),
|
||||
c.West(), c.NW()}
|
||||
}
|
||||
|
||||
func (c *Coordinate) GetNorthCoord() *Coordinate {
|
||||
return &Coordinate{
|
||||
|
Reference in New Issue
Block a user