Skip to content

Commit 6c73192

Browse files
author
Alessandro
committed
export node_count
1 parent 82a1605 commit 6c73192

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/utils.jl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,4 @@ export is_operation
1313
Count the nodes in a symbolic expression tree satisfying `isterm` and `getargs`.
1414
"""
1515
node_count(t) = isterm(t) ? reduce(+, node_count(x) for x in getargs(t), init=0) + 1 : 1
16+
export node_count

0 commit comments

Comments
 (0)