This is a creation in Article, where the information may have evolved or changed.
Go ' s offers extensive support for times and durations; Here is some example
Package Mainimport ("FMT" " Time") Func main () {p:=FMT. PRINTLN Now:=Time . Now () and then:=Time . Date ( the, One, -, -, the, -,651387237, time. UTC) P (then) p (then. Year ()) p (then. Month ()) p (then. Day ()) p (then. Hour ()) p (then. Minute ()) p (then. Second ()) p (then. Nanosecond ()) p (then. Location ()) p (then. Before (now)) p (then. After (now) p (then.) Equal (now)) diff:=Now . Sub (then) p (diff) p (diff. Hours ()) p (diff. Minutes ()) p (diff. Seconds ()) p (diff. nanoseconds ()) p (then. Add (diff)) p (then. ADD (-diff)}
--Geneva- - -: A:14.302895576+0800CST the- One- - -: the:58.651387237+0000UTC theNovember - - the -651387237UTCtruefalsefalse46881h37m15.651508339s46881.621014307872.8128972608584724e+061.6877383565150833e+08168773835651508339 --Geneva- - .: A:14.302895576+0000UTC2004- -- - Ten: $:42.999878898+0000Utc