Skip to Main Content
This paper presents an initiative to teach computer representation of numbers and arithmetic in undergraduate courses in computer science and engineering. The approach is based upon carefully designed practical exercises that highlight the main properties and computational issues of finite-length number representation and arithmetic. In conjunction with the exercises, an auxiliary computer-based environment constitutes a valuable support tool for students to learn and understand the concepts involved. For integer representation, this work has focused on the standard 2's complement. Special emphasis has been put on the algorithms for integer arithmetic operations. For floating-point representation, simpler formats have been used as an introduction to the IEEE Standard 754, with the aim of presenting the fundamentals of the floating-point computation and emphasizing its limitations. This approach could be included in introductory courses related to computer organization, programming, discrete mathematics, or numerical methods.