mirror of
https://github.com/krahets/hello-algo.git
synced 2024-12-26 02:36:28 +08:00
ebf9024136
the chapter of stack and queue, the chapter of tree.
19 lines
325 B
Go
19 lines
325 B
Go
// File: list_node_test.go
|
|
// Created Time: 2022-11-25
|
|
// Author: Reanon (793584285@qq.com)
|
|
|
|
package pkg
|
|
|
|
import (
|
|
"fmt"
|
|
"testing"
|
|
)
|
|
|
|
func TestListNode(t *testing.T) {
|
|
arr := []int{2, 3, 5, 6, 7}
|
|
head := ArrayToLinkedList(arr)
|
|
|
|
PrintLinkedList(head)
|
|
node := GetListNode(head, 5)
|
|
fmt.Println("Find node: ", node.Val)
|
|
}
|