Just added: Algorithms you can run and practice
Python
# Each alert channel gets its own notifier. Run it - all three report the same channel.
def make_senders(channels):
    senders = []
    for name in channels:
        senders.append(lambda: f"alert sent to {name}")
    return senders

for send in make_senders(["email", "slack", "sms"]):
    print(send())