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 16:27Karthik 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 16:28016,551,9637,616,000020,480expected "3470515159949848 ", got "96 6928 109 9784 4661 4172 4117 4079 4067 4050 4085 4058 4059 4135 4050 4117 4042 4041 "
2Oct 5, 2026 16:28016,797,3307,929,000020,480expected "3472574356607895 ", got "96 7240 99 8372 8412 4375 4143 4196 4132 4133 4067 4086 4145 4084 4147 4098 4093 4189 "
3Oct 5, 2026 16:28017,013,7538,103,000020,480expected "3476906919022059 ", got "97 7407 95 10609 8132 4358 4090 4100 4083 4111 4069 4102 4131 4087 4190 4100 4095 4067 "