Java Reference
In-Depth Information
SR 1.25 Suppose a program requires an identifier to represent the sum of the
test scores of a class of students. For each of the following names,
state whether or not each is a good name to use for the identifier.
Explain your answers.
a. x
b. scoreSum
c. sumOfTheTestScoresOfTheStudents
d. smTstScr
SR 1.26 What is white space? How does it affect program execution? How
does it affect program readability?
1.5 Program Development
The process of getting a program running involves various activities. The program
has to be written in the appropriate programming language, such as Java. That
program has to be translated into a form that the computer can execute. Errors
can occur at various stages of this process and must be fixed. Various software
tools can be used to help with all parts of the development process as well. Let's
explore these issues in more detail.
Programming Language Levels
Suppose a particular person is giving travel directions to a friend. That person might
explain those directions in any one of several languages, such as English, Russian, or
Italian. The directions are the same no matter which language is used to explain them,
but the manner in which the directions are expressed is different. The friend must be
able to understand the language being used in order to follow the directions.
Similarly, a problem can be solved by writing a program in one of many pro-
gramming languages, such as Java, Ada, C, C++, C#, Pascal, and Smalltalk. The
purpose of the program is essentially the same no matter which language is used,
but the particular statements used to express the instructions, and the overall
organization of those instructions, vary with each language. A computer must be
able to understand the instructions in order to carry them out.
Programming languages can be categorized into the following four groups.
These groups basically reflect the historical development of computer languages.
machine language
assembly language
 
Search WWH ::




Custom Search