Skip to content

第一周作业#10 - #9

Merged
GeekUniversity merged 4 commits into
algorithm002:masterfrom
James-Ren:master
Jun 10, 2019
Merged

GeekUniversity merged 4 commits into
algorithm002:masterfrom
James-Ren:master

Conversation

@James-Ren

Copy link
Copy Markdown
Contributor

No description provided.

curroute = str + "->" + strconv.Itoa(root.Val)
}
if root.Left == nil && root.Right == nil {
allroutes = append(allroutes, curroute)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

這題我沒用全局變量,然後 append 的時候踩坑。

原來要覆蓋掉原本的 slice header。

if root.Left == nil && root.Right == nil {
  *res = append(*res, path)
}

https://github.com/algorithm002/algorithm/pull/16/files#diff-a90a3d84391f403040404174d3733521R34

GeekUniversity added a commit that referenced this pull request Jun 10, 2019
@GeekUniversity
GeekUniversity merged commit c9360fa into algorithm002:master Jun 10, 2019
GeekUniversity added a commit that referenced this pull request Jun 24, 2019
GeekUniversity added a commit that referenced this pull request Jul 1, 2019
GeekUniversity added a commit that referenced this pull request Aug 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants