You must write a program that reads a binary file from a given path and decodes it into a JSON array of…
You must write a program that reads a binary file from a given path and decodes it into a JSON array of…: a task in TermGrade Environments: 1,004 executable Linux tasks (Harbor dataset). Input format: The binary file consists of a sequence of records. Each record has: - 1 byte: record type…
The task
**Input format:** The binary file consists of a sequence of records. Each record has: - 1 byte: record type (unsigned 8-bit integer) - A variable-length unsigned integer (varint) for the payload length, encoded as unsigned LEB128 - Payload of exactly that many bytes, interpreted according to the record type
Part of ai-and/termgrade-environments.