How to get a timestamp in milliseconds from Erlang


/ Published in: Other
Save to your folder(s)



Copy this code and paste it in your HTML
  1. % gets a timestamp in ms from the epoch
  2. get_timestamp() ->
  3. {Mega,Sec,Micro} = erlang:now(),
  4. (Mega*1000000+Sec)*1000000+Micro.

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.