The task solution is found in the file task.py. To run it using the input example: ./task.py < event_data.txt test_task.py contains unit tests based on pytest. Run them by executing the pytest command in the repository root.