This document discusses event-based programming and how it differs from procedural programming. In event-based programming, code is executed upon activation of events rather than in sequential order. The system waits for user input events, which then trigger program methods. When an input event occurs, a data structure describing the event is placed on an event queue. The program enters an event loop that continuously removes events from the queue and processes them by calling event dispatch routines.