Skip to content

Commit e5adc4b

Browse files
authored
docs: tweak Expression example
1 parent 9752dbb commit e5adc4b

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

test/test_expressions.jl

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -289,19 +289,18 @@ end
289289
a mathematical expression as a tree structure. It combines an
290290
`AbstractExpressionNode` (typically a `Node`) with metadata like operators
291291
and variable names.
292-
293-
Let's explore how to create and work with `Expression` objects:
294292
=#
295293
using DynamicExpressions, Random
296294

297295
# First, let's define our operators and variable names:
298296

299297
operators = OperatorEnum(;
300-
binary_operators=[+, -, *, /], unary_operators=[sin, cos, exp]
298+
binary_operators=(+, -, *, /), unary_operators=(sin, cos, exp)
301299
)
300+
#
302301
variable_names = ["x", "y"]
303302

304-
# Now, let's create a simple Expression manually:
303+
# Now, let's create an Expression manually:
305304
x = Node{Float64}(; feature=1)
306305
x_expr = Expression(x; operators, variable_names)
307306

0 commit comments

Comments
 (0)