Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get the milliseconds from now() in Julia 0.4-pre?

How to get the milliseconds from now()?

Dates.format(now(), "HH:MM:SS.sss")

gives

"18:32:11.000"

where the .sss part is always .000.

like image 928
Ferenc Avatar asked Sep 04 '15 22:09

Ferenc


1 Answers

now() does't record milliseconds:

julia> @show x=now(); @show Dates.millisecond(x); @show Dates.second(x)
x = now() = 2015-09-04T19:09:32
Dates.millisecond(x) = 0
Dates.second(x) = 32
32
like image 105
IainDunning Avatar answered Oct 14 '22 23:10

IainDunning