Quantcast
Channel: First steps - JuliaLang
Viewing all articles
Browse latest Browse all 2795

Fields of an anonymous function?

$
0
0

Looking at some examples of a package I came across this type of behavior:

function f(n)
    a = n
    x -> x^a
end

g = f(2)

g.a # 2

Can someone point out where that is documented?

9 posts - 4 participants

Read full topic


Viewing all articles
Browse latest Browse all 2795

Latest Images

Trending Articles



Latest Images