dsutils

package module
v0.0.0-...-735ead8 Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2023 License: MIT Imports: 1 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

dsutils

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Stack

type Stack[T any] []T

Stack is a generic stack implementation.

func NewStack

func NewStack[T any]() *Stack[T]

NewStack returns a new stack.

func (*Stack[T]) Clear

func (s *Stack[T]) Clear()

Clear clears the stack.

func (*Stack[T]) IsEmpty

func (s *Stack[T]) IsEmpty() bool

IsEmpty returns true if the stack is empty.

func (*Stack[T]) Len

func (s *Stack[T]) Len() int

Len returns the length of the stack.

func (*Stack[T]) Pop

func (s *Stack[T]) Pop() T

Pop removes and returns the last element of the stack.

func (*Stack[T]) Push

func (s *Stack[T]) Push(v T)

NewStack returns a new stack.

func (*Stack[T]) Vector

func (s *Stack[T]) Vector() []string

String returns a string vector representation of all elements in stack.

Directories

Path Synopsis
cmd
splitmarkdown command
table2csv command
pkg

Jump to

Keyboard shortcuts

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