Created with CodeSandbox
Create a calculator using React Framework
- react
- react-dom
- react-scripts
- Working values and result values are always displayed
- Pressing AC button clears input and output values. Calculator returns to default state
- Number cannot begin with multiple zeros
- Any operation (+,-,*,/) can be performed on a chain of numbers of any length and numbers containing decimal points. The correct result will be produced.
- Two '.' in one number is not accepted
- If 2 or more operators are entered consecutively, the operation performed should be the last operator entered
- Pressing an operator immediately following "=" should start a new calculation that operates on the result of the previous evaluation
- Round values to 4 decimal places