0

Python Calculator - Any improvements?

Hi All Can anyone recommend any improvements to the below code that I made? Thanks https://code.sololearn.com/cx574pn4MvZl/?ref=app

11th Jan 2022, 3:07 PM
K Ka
4 odpowiedzi
+ 6
You can add a try-except statement to prevent Zero division error for division operator.
11th Jan 2022, 3:37 PM
Simba
Simba - avatar
+ 1
Simba I have now added this in, thank you!! What do you think?
15th Jan 2022, 3:21 PM
K Ka
0
Create it with functions
11th Jan 2022, 3:24 PM
Krish
Krish - avatar
0
Its_krish01 You have used int, won’t that cause problems if user enters decimal number? Could use float instead
15th Jan 2022, 2:50 PM
K Ka