1
0
gotour-notes/exercises/08-ebt/go.go

19 lines
326 B
Go

package main
import (
"code.google.com/p/go-tour/tree"
"gotour-notes/ebt"
"fmt"
)
func main() {
t := tree.New(1)
ch := make(chan int)
go ebt.Walk(t, ch)
for i := range ch {
fmt.Printf("%d, ", i)
}
fmt.Println()
fmt.Println(ebt.Same(tree.New(1), tree.New(1)))
fmt.Println(ebt.Same(tree.New(1), tree.New(2)))
}