Create a command-line tool /root/fxcalc.py that performs precise arithmetic operations on decimal numbers…
Create a command-line tool /root/fxcalc.py that performs precise arithmetic operations on decimal numbers…: a task in TermGrade Environments: 1,004 executable Linux tasks (Harbor dataset). All numbers are strings like -123.456 , 0.001 , 42 , -0.0 , .5 , -.25 . Scale is a non-negative integer 0–20…
The task
All numbers are strings like `-123.456`, `0.001`, `42`, `-0.0`, `.5`, `-.25`. Scale is a non-negative integer 0–20. Leading zeros and trailing zeros after decimal are allowed in input.
Part of ai-and/termgrade-environments.