How calculate time between two date?

Hi all,

I search to have the duration between tow date create by now().
I’m new julia’s user. I don’t know do this.
Please help me!!

Thank you for your help. :slight_smile:

1 Like

Welcome to the discourse!

I can’t answer your question better then it’s done in the docs: https://docs.julialang.org/en/v1/stdlib/Dates/index.html#Durations/Comparisons-1

3 Likes

Welcome to this fine community!

julia> using Dates

julia> realtime=Dates.now()
2020-06-23T16:59:17.906

julia> elapsed_realtime=Dates.now()-realtime
111 milliseconds

But reading the docs as @Skoffer adviced is always recommended!

1 Like