|
|
|
|
|
by plafl
1613 days ago
|
|
If I understood the article correctly the four type of functions are present in Julia: julia> factorial(3) # term -> term
6
julia> typeof(3) # term -> type
Int64
julia> one(Float32) # type -> term
1.0f0
julia> Vector{Float32} # type -> type
Vector{Float32} (alias for Array{Float32, 1})
And actually more mixed: julia> using StaticArrays
julia> SVector{3, Float32}(1, 2, 3)
3-element SVector{3, Float32} with indices SOneTo(3):
1.0
2.0
3.0
julia> convert(Float32, 1)
1.0f0
Julia is of course dynamic, so maybe it's cheating? I'm writing this comment because all the greek in that cube, and actually using a cube, makes this look like very abstract stuff but I consider Julia a very practical language.> Untyped scripting languages are fine for scripts. Honestly idk why developers write big libraries in untyped languages like JavaScript and Python. And yet it works |
|
I don’t know the peculiarities of julia to comment on this specific language though.