By using
‘typeof(variableName)’ function, you can get the type of the variable. Based on
the value assigned to a variable, Julia infer the type.
julia> a=10 10 julia> typeof(a) Int64 julia> a="Hello" "Hello" julia> typeof(a) ASCIIString julia> a=true true julia> typeof(a) Bool julia> a=123.321 123.321 julia> typeof(a) Float64
No comments:
Post a Comment