The main time measure currently used for real-time languages (worst-case time) is well-known not to be modular in general, which makes average-case analysis notoriously difficult, involving a variety of techniques which typically do not allow for automation. This book introduces the first programming language for which average-case time analysis of its programs is guaranteed to be modular. The book includes sample programs and sample derivations of the average-case time of these programs to illustrate this radically different approach to average-case timing. The book presets a single foundation for Average-Case Analysis, based on the notion of Random Structure Preservation, and solves several well-known open problems discussed by Knuth.