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 15:09Karthik 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 15:10016,272,2257,313,000020,480expected "3472026519244210 ", got "97 6626 100 6068 4983 4282 4080 4140 4082 4081 4089 4076 4088 4056 4159 4086 4091 4148 "
2Oct 5, 2026 15:10016,152,8857,091,000020,480expected "3475735153460974 ", got "96 6409 94 5168 4297 4042 4031 4126 4055 4074 4059 4049 4095 4082 4113 4053 4031 4104 "
3Oct 5, 2026 15:10016,398,5907,554,000020,480expected "3467317271645390 ", got "96 6867 99 7256 5632 4868 4249 4109 4058 4130 4076 4069 4031 4052 4143 4071 4147 4073 "