You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would recommend this changes as current code is not working even if error is thrown while checking for division by zero. i.e,
Below code is correct in my view, but still test case is failing.
divide(num) {
if (num === 0) throw new Error("NaN");
this.result /= num;
}
The text was updated successfully, but these errors were encountered:
ankit-95
changed the title
Update required in Test Case for Calculator.js - Hard Problem in 01-js
Updation required in Test Case for Calculator.js - Hard Problem in 01-js
Jun 12, 2023
Before :
After :
I would recommend this changes as current code is not working even if error is thrown while checking for division by zero. i.e,
Below code is correct in my view, but still test case is failing.
The text was updated successfully, but these errors were encountered: