The function discount_on_voucher
checks for specific voucher codes and applies a discount accordingly. The available vouchers according to the code are 'Flat 50', 'Flat 30', and 'Flat 20'.
When the function is called with the parameters voucher='Flat 75'
and amount=1000
, it does not match any of the specified voucher cases. Therefore, the discount
variable remains 0
.
As a result, the output of the code will be:
Discount is 0.
So the correct response is: The output will be “Discount is 0.”