-
` :# Subtraction operator example
a = 10
b = 5
result = a - b
print("The difference between", a, "and", b, "is", result)
In the above program, we first assign the integer values `10
` and `5
` to the variables `a
` and `b
`, respectively. We then use the subtraction operator `-
` to subtract `b
` from `a
`, and assign the result to the variable `result`.
Finally, we use the `print()
` function to print a message that displays the values of `a
`, `b
`, and `result`, as well as a message indicating that `result
` is the difference between `a` and `b`.
When we run the program, it will output the following message :
The difference between 10 and 5 is 5
b
` from `a
` using the subtraction operator `-
`, and displays the result using the `print()
` function.