开发者

Figure out type of timestamp

I've occured a strange time-format, and i can't figure out how to convert it to a readable format.

A couple of timestamps from today are

开发者_运维知识库
32400683 (this morning)
41891077
56517540
57390993
58728120 (this afternoon)


That looks like milliseconds starting from midnight.

Divide by 1000 to get seconds, by 60 to get minutes (60,000), and 60 again to get hours (3,600,000).

That gives you:

9.0  => 09:00 (this morning)
11.6 => 11:36
15.7 => 15:42
15.9 => 15:54
16.3 => 16:18 (this afternoon)
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜