November 2017
Beginner
316 pages
6h 40m
English
We now know how to read data from the user. But how about if we had a text file that was supposed to be read? We may then have to take the help of the open function, which helps us read files from the system.
On a closer look at the open function, we can see it has multiple ways of being invoked:
julia> methods(open) # 8 methods for generic function "open": open(fname::AbstractString) in Base at iostream.jl:113 open(fname::AbstractString, rd::Bool, wr::Bool, cr::Bool, tr::Bool, ff::Bool) in Base at iostream.jl:103 open(fname::AbstractString, mode::AbstractString) in Base at iostream.jl:132 open(f::Function, cmds::Base.AbstractCmd, args...) in Base at process.jl:599 open(f::Function, args...) in Base at iostream.jl:150 ...
Read now
Unlock full access