Parse dateTime Andrey Tsvetkov

Compute the sum of 5,000,000 UTC Unix timestamps as fast as possible.

Input

One RFC 3339 datetime per line on STDIN:

2017-05-04T14:31:30-03:00
2046-06-23T11:51:56-06:00
2031-08-14T13:18:38+06:00
2048-04-14T05:55:06-09:00
1980-08-28T00:43:03+02:00

Output

Print the sum of all UTC Unix timestamps (int64) to STDOUT.

Constraints

  • Datetimes are in the range 1950-01-01T00:00:00 to 2050-12-31T23:59:59
Back to listOct 5, 2026 13:41Karthik ReddyKarthik ReddyError
Source Code

Source code access is restricted. Log in to request access.

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Oct 5, 2026 13:42088,714,11079,832,00002,113,536expected "3474049170377743 ", got " 0=7596 nopf=7006 align=6439 skel=6320 skelns=6286 skelal=6265 0=6612 nopf=6991 align=6436 skel=6309 skelns=6279 skelal=6264 "
2Oct 5, 2026 13:42088,218,72079,393,00002,113,536expected "3471541336622985 ", got " 0=6755 nopf=7216 align=6442 skel=6318 skelns=6271 skelal=6242 0=6627 nopf=7203 align=6439 skel=6324 skelns=6264 skelal=6253 "
3Oct 5, 2026 13:42087,766,99878,951,00002,113,536expected "3471585440430727 ", got " 0=6746 nopf=7053 align=6432 skel=6295 skelns=6259 skelal=6244 0=6622 nopf=7041 align=6427 skel=6288 skelns=6268 skelal=6246 "