Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
1 Some Basic Ideas Contents · · · · Computer software and data, and the role of `high-level' languages Program control structures Pseudocode and top-down design Classes and object-oriented programming 1.1 INTRODUCTION In this chapter, we review some fundamental concepts underlying computer programs and software development. 1.2 WHAT IS A COMPUTER PROGRAM? Computer programs perform tasks and solve problems by manipulating data. The data might be the characters that my word processor is assembling right now to form this sentence, the text and images comprising a Web page or again the satellite navigation signals and other information needed to fly an airliner across a continent. Representing data appropriately so that they may be stored and manipulated correctly and effi ciently is a study area of major concern. Inside the machine, all items of data are stored as `bits' of binary logic, just as are the program's instructions. In the early days of computing, programming involved working at this very low level, translating instructions and data into 0's and 1's and flipping switches in order to store them in the machine's limited memory, before executing the program. Writing programs using `machine code' was tedious, prone to error and involved mental gymnastics on the part of the programmer to transform the problem to be solved into operations to move numbers around between the various parts of the machine's hardware.