C H A P T E R 2
Discovering Classes and Objects
cancreatesimpleapplications(suchas HelloWorld andtheapplicationsmentionedin
languages such as C.
Note Structured programming is a programming paradigm that enforces a logical
structure on programs through data structures (named aggregates of data items), func-
tions (named blocks of code that return values to the code that calls [passes program
execution to] them), and procedures (named blocks of code that don't return values
to their callers). Structured programs use sequence (one statement follows another
ming constructs; use of the potentially harmful GOTO statement (see ht-
tp://en.wikipedia.org/wiki/GOTO ) is discouraged.
Structured programs separate data from behaviors. This separation makes it difficult
are typically easier to understand and maintain.
fields and methods. After learning about class and object initialization, you move bey-
ond this object-based programming model and dive into object-oriented programming ,
by exploring Java's inheritance- and polymorphism-oriented language features.