programming/iOS
Apple Challenge 1 /* A FunkyNotificationCenter object that broadcasts events within a program. Code that wants to observe notification events registers a closure via the addObserver(:for:block:) method. Code that sends notifications uses the post(notificationName:) method. Each closure that was registered for that notification name should be called. */ import Foundation class FunkyNotificationCenter { typealias notifBlock = () -> Void var entries: [String: [notifBlock]] = [:] init() // mynotif, block1, block2 /// Post a notification with the given name....