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:26Karthik 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:27016,907,0158,020,000020,480expected "3468689312044167 ", got "96 7329 100 13155 4662 4281 4171 4201 4147 4110 4101 4081 4110 4103 4062 4200 4078 4112 "
2Oct 5, 2026 16:27016,088,7667,263,000020,480expected "3471881470374446 ", got "95 6597 93 6007 4375 4315 4125 4183 4177 4096 4099 4094 4105 4090 4077 4200 4131 4188 "
3Oct 5, 2026 16:27016,798,0647,900,000020,480expected "3472031840078308 ", got "95 7200 110 12289 4650 4196 4214 4110 4051 4103 4052 4078 4077 4112 4089 4073 4121 4052 "