Ad
Code
Diff
  • def Calculator(a, b, c='error'):
        try:
            return eval(str(b)+a+str(c))
        except:
            return 0
    • def Calculator(expression):
    • def Calculator(a, b, c='error'):
    • try:
    • return eval(expression)
    • return eval(str(b)+a+str(c))
    • except: