Find the sum of all left leaves in a given binary tree.
Example:
3
/ \
9 20
/ \
15 7
There are two left leaves in the bi...
admin
4年前 (2016-10-07) 1057℃ 0评论
0喜欢
Go
package main
import (
"fmt"
)
type Tree struct {
data string
left *Tree
right *T...
admin
4年前 (2016-10-07) 1015℃ 0评论
0喜欢
搜索二叉树
Go
package main
import (
"fmt"
)
type Tree struct {
data int
root *Tree
left ...
admin
4年前 (2016-10-07) 1075℃ 0评论
0喜欢
C++中利用指针交换两个数:
#include <iostream>
using namespace std;
void exchange(int*, int*);
void swap(int *, int *);
int main()
{
...
screenpage
5年前 (2015-11-19) 1206℃ 0评论
0喜欢