Implement a command-line tool at /app/bin/tlv2json that reads a binary TLV (Type-Length-Value) record file…
Implement a command-line tool at /app/bin/tlv2json that reads a binary TLV (Type-Length-Value) record file…: a task in TermGrade Environments: 1,004 executable Linux tasks (Harbor dataset). Input binary format: - Each record: TYPE (1 byte, unsigned) LENGTH (unsigned varint) VALUE (LENGTH bytes) -…
The task
**Input binary format:** - Each record: `TYPE` (1 byte, unsigned) | `LENGTH` (unsigned varint) | `VALUE` (LENGTH bytes) - Varint encoding: unsigned LEB128 (little-endian base-128). Each byte uses 7 data bits + 1 continuation bit (MSB=1 means more bytes follow). - TYPE values: 0x01=string (UTF-8), 0x02=integer…
Part of ai-and/termgrade-environments.