Expected behaviour of println.(Array) (or @. println(Array) )

Calling f.(x) returns an array (or other container) holding the value of f(x_i) for each x_i in x:

julia> f(x) = 2 * x
f (generic function with 1 method)

julia> f.([1, 2, 3])
3-element Array{Int64,1}:
 2
 4
 6

If f(x) returns nothing, then you will get a collection of nothings:

julia> g.([1, 2, 3])
3-element Array{Nothing,1}:
 nothing
 nothing
 nothing

println(x) returns nothing:

julia> result = println(1.0)
1.0

julia> result === nothing
true

so println.(x) returns a vector of nothings, which then get automatically printed because the REPL always prints out the return value of the last expression.

julia> println.([1, 2, 3])
1
2
3
3-element Array{Nothing,1}:
 nothing
 nothing
 nothing

Edit: @dmolina beat me to it!