Queueing theory is the mathematical study of waiting lines or queues. A queue refers to a sequence of entities waiting to be served based on the first-in-first-out (FIFO) principle. Common examples include lines at checkout counters. Key elements of queueing theory include the arrival and service processes, queue discipline, capacity, length, waiting time, and service time. The M/M/1 queue model analyzes a single server queue where arrivals and services times follow Markovian processes. It is used to predict performance and evaluate system design.