Skip to content

Commit f704536

Browse files
committed
clarify local in trapezoidal example
1 parent af51162 commit f704536

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/src/literate/integration/integration.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ function trapezoidal_parallel(a, b, N)
8080
n = N ÷ nthreads()
8181
h = (b - a) / N
8282
return tmapreduce(+, 1:nthreads()) do i
83-
local α = a + (i - 1) * n * h
83+
local α = a + (i - 1) * n * h # the local keywords aren't necessary but good practice
8484
local β = α + n * h
8585
trapezoidal(α, β, n; h)
8686
end

0 commit comments

Comments
 (0)