mchirico / zDaily

Playground to hack and test ideas with Zoe
1 stars 2 forks source link

Day 19: Create your own linked list. #21

Open mchirico opened 3 years ago

mchirico commented 3 years ago

Linked List

Video

For this, can you create your own simple example of a linked list?

Code

tacomonkautobot[bot] commented 3 years ago

mchirico, Thanks for opening this issue!

ZoeChiri commented 3 years ago

type Node struct {     prev Node     next Node     key  interface{} }   type List struct {     head Node     tail Node }

func main() {     link := List{}     link.Insert(2)     link.Insert(3)     link.Insert(1)

}