Answer to Question #313613 in Python for Sai

Question #313613

How to find input as operation



Explain:



It is subtraction operator given two numbers -150 - -100



Input:



-150 - -100



Output:



50



Input:



150 + 50



Output:



250

1
Expert's answer
2022-03-18T02:26:39-0400
def sub_add(num1, num2):
    if num1 <  and num2 < 0:
        return abs(num1-num2)
    else:
        return num1 + num2

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS