events k_tabk_spacek_plusk_ k_ k_atk_ak_bk_zk_deltek_downk_leftk_rightk_left etc further keyboard constants are provided for modifier states that can be combined with the above such as kmod_shiftkmod_capskmod_ctrl and kmod_alt the event queue events are supplied to pygame application via the event queue the event queue is used to collect together events as they happen for examplelet us assume that user clicks on the mouse twice and key twice before program has chance to process themthen there will be four events in the event queue as shown belowthe application can then obtain an iterable from the event queue and process through the events in turn while the program is processing these events further events may occur and will be added to the event queue when the program has finished processing the initial collection of events it can obtain the next set of events to process one significant advantage of this approach is that no events are ever lostthat is if the user clicks the mouse twice while the program is processing previous set of eventsthey will be recorded and added to the event queue another advantage is that the events will be presented to the program in the order that they occurred the pygame event get(function will read all the events currently on the event queue (removing them from the event queuethe method returns an eventlist which is an iterable list of the events read each event can then be processed in turn for examplefor event in pygame event get()if event type =pygame quitprint('received quit event:'elif event type =pygame mousebuttondownprint('received mouse event'elif event type =pygame keydownprint('received keydown event'