HF RL Explorer

Create a command-line tool /app/calc that performs exact fixed-point arithmetic on decimal numbers. The tool…

Create a command-line tool /app/calc that performs exact fixed-point arithmetic on decimal numbers. The tool…: a task in TermGrade Environments: 1,004 executable Linux tasks (Harbor dataset). Input contract: - The expression consists of numbers, operators + , - , , / , and parentheses ( ) . -…

The task

**Input contract:** - The expression consists of numbers, operators `+`, `-`, `*`, `/`, and parentheses `(` `)`. - Numbers are decimal strings with an optional leading minus sign and exactly ONE decimal point (e.g., `3.14`, `-0.001`, `42.0`). Scientific notation is NOT allowed. - Leading zeros on the integer part are…

Part of ai-and/termgrade-environments.