Skip to content

Commit a54913a

Browse files
committed
add missing file
1 parent f84adec commit a54913a

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

misc.go

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
package leaves
2+
3+
func GetNLeaves(trees []lgTree) []int {
4+
result := make([]int, len(trees))
5+
for idx, tree := range trees {
6+
result[idx] = tree.nLeaves()
7+
}
8+
9+
return result
10+
}

0 commit comments

Comments
 (0)