Strategy puts a family of interchangeable algorithms behind one interface. The client (the context) holds a strategy and delegates the work to it, so the algorithm can be chosen or replaced without changing the client. It is the object-oriented answer to a growing if/elif chain.
The problem: an if-chain
Here the order total depends on a discount kind. Every new discount edits total, and a typo in kind surfaces only at runtime. The function knows all algorithms, so it breaks the open/closed principle.
def total(items, kind, value=0):
amount = sum(items)
if kind == "none":
return amount
elif kind == "percent":
return amount * (100 - value) // 100
elif kind == "fixed":
return max(amount - value, 0)
raise ValueError(kind)
print(total([40, 60, 50], "percent", 10), total([40, 60, 50], "fixed", 30))135 120