linkedlistmap

package
v0.0.0-...-73cdf94 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LinkedList

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

func NewLinkedList

func NewLinkedList() *LinkedList

func (*LinkedList) Add

func (l *LinkedList) Add(k int, v interface{})

在链表的index位置添加新的元素e

func (*LinkedList) Contains

func (l *LinkedList) Contains(k int) bool

func (*LinkedList) Get

func (l *LinkedList) Get(index int) interface{}

获取链表中index位置的元素

func (*LinkedList) IsEmpty

func (l *LinkedList) IsEmpty() bool

func (*LinkedList) Len

func (l *LinkedList) Len() int

func (*LinkedList) Remove

func (l *LinkedList) Remove(index int) interface{}

func (*LinkedList) Set

func (l *LinkedList) Set(index int, e interface{})

func (*LinkedList) String

func (l *LinkedList) String() string

type LinkedListMap

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

基于linkedlist实现的Map

func (*LinkedListMap) Add

func (m *LinkedListMap) Add(k int, v interface{})

func (*LinkedListMap) Contains

func (m *LinkedListMap) Contains(i int) bool

func (*LinkedListMap) Get

func (m *LinkedListMap) Get(i int) interface{}

func (*LinkedListMap) IsEmpty

func (m *LinkedListMap) IsEmpty() bool

func (*LinkedListMap) Len

func (m *LinkedListMap) Len() int

func (*LinkedListMap) Remove

func (m *LinkedListMap) Remove(i int) interface{}

func (*LinkedListMap) Set

func (m *LinkedListMap) Set(k int, v interface{})

type ListNode

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

Jump to

Keyboard shortcuts

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