1 2 3 4 5 6
def loss_amount(actual_cost,sale_amount): if(sale_amount > actual_cost): amount = sale_amount - actual_cost return amount else: return None