0

I wrote this code on the simple calculator challenge, it said I was incorrect, even though the calculator can add 2 numbers.

https://code.sololearn.com/c23kBjB59TYr/?ref=app

25th Oct 2020, 10:47 PM
ydk_my_name
3 Answers
+ 4
The input prompts weren't wanted. Just keep it really simple, e.g. print(int(input()) + int(input())) BTW You don't need print("") to print a blank line. print() does the same thing 🙂
26th Oct 2020, 3:07 AM
David Ashton
David Ashton - avatar
+ 3
When solving for automated test cases, you need to make sure your output matches the expected output, otherwise the comparison is going to fail. In this particular case, the challenge only wants you to print the result, and nothing else.
25th Oct 2020, 10:58 PM
Shadow
Shadow - avatar
+ 2
thank you so much, it worked!
26th Oct 2020, 9:34 PM
ydk_my_name