tour: golang.org/x/tour/tree Index | Files

package tree

import "golang.org/x/tour/tree"

Index

Package Files

tree.go

type Tree Uses

type Tree struct {
    Left  *Tree
    Value int
    Right *Tree
}

A Tree is a binary tree with integer values.

func New Uses

func New(k int) *Tree

New returns a new, random binary tree holding the values k, 2k, ..., 10k.

func (*Tree) String Uses

func (t *Tree) String() string

Package tree imports 2 packages (graph) and is imported by 12 packages. Updated 2017-10-17. Refresh now. Tools for package owners.