[Solved] Basic Python 2.7 Math Script (4 variables and 3 consecutive math operations) [closed]


If I understand the problem correctly, I would ask a user what operation he wants to go with:

math_option =raw_input('Choose the math operation: ')

and later on check what option was chosen:

if math_option == "add":
    print add(x, y)
if math_option == "multiply":
     add_num = add(x,y)
     mul_num = multiply(math_option,z)  
     print mul_num

and so on

1

solved Basic Python 2.7 Math Script (4 variables and 3 consecutive math operations) [closed]