Open sevanspowell opened 7 years ago
The CalculatorBrain factorial function currently takes Doubles as arguments and works by truncating the Double to Int.
The calculator should instead not allow Doubles as input.
The factorial function also does not handle overflow/large input numbers.
Maybe return NaN for input with fractional part. Let calculator display handle NaN case and display a message such as "Not a number".
The CalculatorBrain factorial function currently takes Doubles as arguments and works by truncating the Double to Int.
The calculator should instead not allow Doubles as input.
The factorial function also does not handle overflow/large input numbers.