|
|
@ -1,5 +1,10 @@ |
|
|
|
package correct |
|
|
|
package correct |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import ( |
|
|
|
|
|
|
|
"math/rand" |
|
|
|
|
|
|
|
"strconv" |
|
|
|
|
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|
type TreeNodeL struct { |
|
|
|
type TreeNodeL struct { |
|
|
|
Left *TreeNodeL |
|
|
|
Left *TreeNodeL |
|
|
|
Val int |
|
|
|
Val int |
|
|
@ -23,7 +28,6 @@ func checkIfEq(t1 *TreeNodeL, t2 *TreeNodeL) bool { |
|
|
|
return t1.Val == t2.Val && checkIfEq(t1.Right, t2.Right) && checkIfEq(t1.Left, t2.Left) |
|
|
|
return t1.Val == t2.Val && checkIfEq(t1.Right, t2.Right) && checkIfEq(t1.Left, t2.Left) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
type stuTreeNode = TreeNodeL |
|
|
|
type stuTreeNode = TreeNodeL |
|
|
|
type solTreeNode = correct.TreeNodeL |
|
|
|
type solTreeNode = correct.TreeNodeL |
|
|
|
|
|
|
|
|
|
|
|