list

package
v0.0.0-...-b58111f Latest Latest
Warning

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

Go to latest
Published: Jun 25, 2025 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type List

type List struct {
	Count int
	// contains filtered or unexported fields
}

List represents a list of nodes.

func (*List) AddBetter

func (l *List) AddBetter(data string) *Node

AddBetter uses the `n` variable for the node. This variable is better because it doesn't get in the way of readability. Now the switch/case logic becomes the focal point when reading the code.

func (*List) AddOk

func (l *List) AddOk(data string) *Node

AddOk uses the `newNode` variable for the node. This variable name gets in the way of readability. It becomes the focal point when trying to read the code.

type Node

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

Node represents the data being stored.

Jump to

Keyboard shortcuts

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