Basic calculator

2 testcases are correct but rest 4 are given wrong answer
help me find the flaw in my code

Hi Vaibhav, your code is great.
Actually, once you submit your code online then, it matches the output of your code with output of the test cases(these outputs are also case sensitive). So, you have to match the exact correct output to pass all the test cases.
I have added one comment in this code.

If you have any other doubts, feel free to ask.

1 Like