Java 5 Illuminated : An Active Learning Approach

by ;
Edition: CD
Format: Paperback
Pub. Date: 2005-02-28
Publisher(s): Jones & Bartlett
List Price: $118.95

Rent Textbook

Select for Price
There was a problem. Please try again later.

New Textbook

We're Sorry
Sold Out

Used Textbook

We're Sorry
Sold Out

eTextbook

We're Sorry
Not Available

Summary

With a variety of interactive learning features and user-friendly pedagogy,Java 5 Illuminatedprovides a comprehensive introduction to programming using the most current version of the Java language, Java 5. In addition to providing all of the material necessary for a complete introductory course in Java programming, the book also features flexible coverage of other topics of interest, including Graphical User Interfaces, data structures, file input and output, and applets. Object-Oriented Programming concepts are developed progressively and reinforced through numerous Programming Activities, allowing students to fully understand and implement both basic and sophisticated techniques at a pace which is neither too fast nor too slow. OO concepts are blended appropriately with fundamental programming techniques, including accumulation, counting, finding maximum and minimum values, and using flag and toggle variables, and supplemented with coverage of sound software engineering practices. Distinguishing this text from other introductory Java books is the authors' extensive use of an "active learning" approach to presenting the material through abundant use of graphics, visualization exercises, animations, numerous full and partial program examples, group projects, and best practices. These and other pedagogical devices facilitate hands-on, interactive learning, and make the book equally appropriate for use in "traditional" lecture environments, a computer-equipped classroom, or lab environment. Java 5 Illuminated Errata Sheet

Table of Contents

Introduction to Programming and the Java Language
Basic Computer Concepts
3(6)
Hardware
3(4)
Operating Systems
7(1)
Application Software
8(1)
Computer Networks and the Internet
8(1)
Practice Activity: Displaying System Configuration
9(3)
Displaying Windows Configuration Information
10(1)
Displaying Unix/Linux Configuration Information
10(2)
Data Representation
12(6)
Binary Numbers
12(3)
Using Hexadecimal Numbers to Represent Binary Numbers
15(2)
Representing Characters with the Unicode Character Set
17(1)
Programming Languages
18(4)
High- and Low-Level Languages
18(2)
An Introduction to Object-Oriented Programming
20(1)
The Java Language
20(2)
An Introduction to Programming
22(11)
Programming Basics
22(1)
Program Design with Pseudocode
23(3)
Developing a Java Application
26(1)
Programming Activity 1: Writing a First Java Application
27(6)
Chapter Summary
33(2)
Exercises, Problems, and Projects
35(7)
Programming Building Blocks---Java Basics
Java Application Structure
42(3)
Data Types, Variables, and Constants
45(15)
Declaring Variables
46(1)
Integer Data Types
47(1)
Floating-Point Data Types
48(1)
Character Data Type
48(1)
Boolean Data Type
49(1)
Initial Values and Literals
49(5)
String Literals and Escape Sequences
54(3)
Constants
57(3)
Programming Activity 1: Exploring Data Types
60(3)
Expressions and Arithmetic Operators
63(16)
The Assignment Operator and Expressions
63(1)
Arithmetic Operators
64(2)
Operator Precedence
66(1)
Integer Division and Modulus
67(3)
Division by Zero
70(1)
Mixed-Type Arithmetic and Type Casting
71(4)
Shortcut Operators
75(4)
Programming Activity 2: Exercising the Arithmetic Operators
79(2)
Chapter Summary
81(2)
Exercises, Problems, and Projects
83(9)
Object-Oriented Programming, Part 1: Using Classes
Class Basics and Benefits
92(3)
Creating Objects Using Constructors
95(3)
Calling Methods
98(5)
Using Object References
103(4)
Programming Activity 1: Calling Methods
107(2)
Calling Static Methods and Using Static Class Variables
109(2)
Using Predefined Classes
111(43)
Java Packages
111(1)
The String Class
112(4)
The length Method
116(1)
The to UpperCase and toLowerCase Methods
117(1)
The indexOf Methods
117(1)
The charAt and substring Methods
117(2)
Using System.out
119(3)
Formatting Output
122(1)
The NumberFormat Class
122(2)
The DecimalFormat Class
124(4)
The Math Class and Random Numbers
128(3)
The pow Method
131(1)
The round Method
132(1)
The min and max Methods
133(1)
The random Method
134(4)
The Integer, Double, and Other Wrapper Classes
138(3)
Input and Output Using JOptionPane Dialog Boxes
141(5)
Input from the Console Using the Scanner Class
146(8)
Programming Activity 2: Using Predefined Classes
154(3)
Chapter Summary
157(2)
Exercises, Problems, and Projects
159(16)
Introduction to Applets and Graphics
Applet Structure
175(3)
Executing an Applet
178(2)
Drawing Shapes with Graphics Methods
180(10)
Using Color
190(6)
Programming Activity 1: Writing an Applet with Graphics
196(1)
Chapter Summary
197(1)
Exercises, Problems, and Projects
198(8)
Flow of Control, Part 1: Selection
Forming Conditions
206(9)
Equality Operators
207(1)
Relational Operators
208(1)
Logical Operators
209(4)
DeMorgan's Laws
213(2)
Simple Selection with if
215(3)
Selection Using if/else
218(3)
Selection Using if/else if
221(4)
Sequential and Nested if/else Statements
225(7)
Sequential if/else Statements
225(1)
Finding the Minimum or Maximum Values
225(3)
Nested if/else Statements
228(1)
Dangling Else
229(3)
Testing Techniques for if/else Statements
232(1)
Programming Activity 1: Working with if/else
233(3)
Comparing Floating-Point Numbers
236(4)
Comparing Objects
240(6)
The equals Method
240(2)
String Comparison Methods
242(4)
The Conditional Operator (?:)
246(2)
The switch Statement
248(9)
Programming Activity 2: Using the switch Statement
257(3)
Chapter Summary
260(1)
Exercises, Problems, and Projects
261(15)
Flow of Control, Part 2: Looping
Event-Controlled Loops Using while
276(1)
General Form for while Loops
277(2)
Event-Controlled Looping
279(8)
Reading Data from the User
280(3)
Reading Data from a Text File
283(4)
Looping Techniques
287(19)
Accumulation
287(3)
Counting Items
290(3)
Calculating an Average
293(3)
Finding Maximum or Minimum Values
296(3)
Animation
299(7)
Type-Safe Input Using Scanner
306(4)
Constructing Loop Conditions
310(8)
Testing Techniques for while Loops
318(2)
Event-Controlled Loops Using do/while
320(3)
Programming Activity 1: Using while Loops
323(4)
Count-Controlled Loops Using for
327(12)
Basic Structure of for Loops
327(1)
Constructing for Loops
328(10)
Testing Techniques for for Loops
338(1)
Nested Loops
339(7)
Programming Activity 2: Using for Loops
346(3)
Chapter Summary
349(2)
Exercises, Problems, and Projects
351(15)
Object-Oriented Programming, Part 2: User-Defined Classes
Defining a Class
366(2)
Defining Instance Variables
368(1)
Writing Class Methods
369(2)
Writing Constructors
371(7)
Writing Accessor Methods
378(4)
Writing Mutator Methods
382(5)
Writing Data Manipulation Methods
387(5)
Programming Activity 1: Writing a Class Definition, Part 1
392(3)
The Object Reference this
395(1)
The toString and equals Methods
396(5)
Static Class Members
401(6)
Graphical Objects
407(7)
Enumeration Types
414(7)
Programming Activity 2: Writing a Class Definition, Part 2
421(4)
Creating Packages
425(8)
Generating Web-Style Documentation with Javadoc
433(6)
Chapter Summary
439(2)
Exercises, Problems, and Projects
441(20)
Single-Dimensional Arrays
Declaring and Instantiating Arrays
461(3)
Declaring Arrays
461(1)
Instantiating Arrays
462(1)
Combining the Declaration and Instantiation of Arrays
463(1)
Assigning Initial Values to Arrays
464(1)
Accessing Array Elements
464(5)
Aggregate Array Operations
469(18)
Printing Array Elements
470(1)
Reading Data into an Array
471(2)
Summing the Elements of an Array
473(1)
Finding Maximum or Minimum Values
474(1)
Copying Arrays
475(4)
Changing the Size of an Array
479(2)
Comparing Arrays for Equality
481(3)
Displaying Array Data as a Bar Chart
484(3)
Programming Activity 1: Working with Arrays
487(5)
Using Arrays in Classes
492(9)
Using Arrays in User-Defined Classes
492(7)
Retrieving Command Line Arguments
499(2)
Searching and Sorting Arrays
501(25)
Sequential Search of an Unsorted Array
501(4)
Selection Sort
505(6)
Bubble Sort
511(7)
Sorting Arrays of Objects
518(2)
Sequential Search of a Sorted Array
520(1)
Binary Search of a Sorted Array
521(5)
Programming Activity 2: Searching and Sorting Arrays
526(3)
Using Arrays as Counters
529(5)
Chapter Summary
534(1)
Exercises, Problems, and Projects
535(22)
Multidimensional Arrays and the ArrayList Class
Declaring and Instantiating Multidimensional Arrays
557(7)
Declaring Multidimensional Arrays
557(2)
Instantiating Multidimensional Arrays
559(1)
Combining the Declaration and Instantiation of Multidimensional Arrays
560(1)
Assigning Initial Values to Multidimensional Arrays
560(4)
Accessing Multidimensional Array Elements
564(6)
Aggregate Two-Dimensional Array Operations
570(15)
Processing All the Elements of a Two-Dimensional Array
570(3)
Processing a Given Row of a Two-Dimensional Array
573(2)
Processing a Given Column of a Two-Dimensional Array
575(2)
Processing a Two-Dimensional Array One Row at a Time
577(2)
Processing a Two-Dimensional Array One Column at a Time
579(3)
Displaying Two-Dimensional Array Data as a Bar Chart
582(3)
Two-Dimensional Arrays Passed To and Returned From Methods
585(5)
Programming Activity 1: Working with Two-Dimensional Arrays
590(5)
Other Multidimensional Arrays
595(3)
The ArrayList Class
598(13)
Declaring and Instantiating ArrayList Objects
599(2)
Methods of the ArrayList Class
601(1)
Looping Through an ArrayList Using an Enhanced for Loop
601(4)
Using the ArrayList Class in a Program
605(6)
Programming Activity 2: Working with the ArrayList Class
611(6)
Chapter Summary
617(1)
Exercises, Problems, and Projects
618(23)
Object-Oriented Programming, Part 3: Inheritance, Polymorphism, and Interfaces
Inheritance
641(1)
Inheritance Design
642(17)
Inherited Members of a Class
643(4)
Subclass Constructors
647(5)
Adding Specialization to the Subclass
652(2)
Overriding Inherited Methods
654(5)
The Protected Access Modifier
659(8)
Programming Activity 1: Using Inheritance
667(4)
Abstract Classes and Methods
671(10)
Polymorphism
681(2)
Programming Activity 2: Using Polymorphism
683(7)
Interfaces
690(10)
Chapter Summary
700(2)
Exercises, Problems, and Projects
702(18)
Exceptions and Input/Output Operations
Simple Exception Handling
720(19)
Using try and catch Blocks
721(10)
Catching Multiple Exceptions
731(4)
User-Defined Exceptions
735(4)
The java.io Package
739(1)
Reading from the Java Console
740(9)
Reading and Writing Text Files
749(11)
Reading Text Files
750(4)
Writing to Text Files
754(4)
Appending to Text Files
758(2)
Reading Structured Text Files
760(9)
Parsing a String Using StringTokenizer
761(2)
Reading Structured Data Using StringTokenizer
763(6)
Programming Activity 1: Reading from a Structured Text File
769(4)
Writing and Appending to Structured Text Files
773(3)
Reading and Writing Objects to a File
776(10)
Writing Objects to Files
776(6)
Reading Objects from Files
782(4)
Programming Activity 2: Reading Objects from a File
786(4)
Chapter Summary
790(1)
Exercises, Problems, and Projects
791(23)
Graphical User Interfaces
GUI Applications Using JFrame
814(5)
GUI Components
819(4)
A Simple Component: JLabel
823(4)
Event Handling
827(5)
Text Fields
832(6)
Command Buttons
838(4)
Radio Buttons and Checkboxes
842(9)
Programming Activity 1: Working with Buttons
851(3)
Lists
854(4)
Combo Boxes
858(8)
Adapter Classes
866(1)
Mouse Movements
867(11)
Layout Managers: GridLayout
878(9)
Layout Managers: BorderLayout
887(6)
Using Panels to Nest Components
893(5)
Programming Activity 2: Working with Layout Managers
898(5)
Chapter Summary
903(2)
Exercises, Problems, and Projects
905(21)
Recursion
Simple Recursion: Identifying the General and Base Cases
926(4)
Recursion with a Return Value
930(11)
Computing the Factorial of a Number
931(5)
Computing the Greatest Common Divisor
936(5)
Recursion with Two Base Cases
941(4)
Programming Activity 1: Checking for a Palindrome
945(5)
Binary Search Revisited: A Recursive Solution
950(6)
Programming Activity 2: The Towers of Hanoi
956(6)
Animation Using Recursion
962(4)
Recursion Versus Iteration
966(2)
Chapter Summary
968(1)
Exercises, Problems, and Projects
969(15)
An Introduction to Data Structures
Linked List
984(21)
Linked-List Concepts and Structure
984(2)
A Linked-List Shell
986(6)
Generating an Exception
992(1)
Other Methods of a Linked List
993(8)
Testing a Linked-List Class
1001(4)
Implementing a Stack Using a Linked List
1005(4)
Implementing a Queue Using a Linked List
1009(5)
Array Representation of Stacks
1014(5)
Programming Activity 1: Writing Methods for a Stack Class
1019(4)
Array Representation of Queues
1023(8)
Sorted Linked Lists
1031(9)
Programming Activity 2: Writing Insert and Delete Methods for a Sorted Linked List
1040(5)
Doubly Linked Lists
1045(5)
Recursively Defined Linked Lists
1050(9)
Chapter Summary
1059(1)
Exercises, Problems, and Projects
1060(21)
Appendix A Java Reserved Words and Keywords
1081(2)
Appendix B Operator Precedence
1083(2)
Appendix C The Unicode Character Set
1085(2)
Appendix D Representing Negative Integers
1087(4)
Appendix E Representing Floating-Point Numbers
1091(4)
Appendix F Java Classes APIs
1095(34)
ActionEvent
1095(1)
ActionListener Interface
1096(1)
ArrayList
1096(1)
BorderLayout
1097(1)
BufferedReader
1097(1)
BufferedWriter
1098(1)
ButtonGroup
1099(1)
Color
1099(1)
Container
1100(1)
DecimalFormat
1100(1)
Double
1101(1)
Enum
1102(1)
Exception
1102(1)
File
1103(1)
FileInputStream
1103(1)
FileOutputStream
1103(1)
FileReader
1104(1)
FileWriter
1104(1)
FlowLayout
1104(1)
Graphics
1104(2)
GridLayout
1106(1)
InputStreamReader
1106(1)
Integer
1106(1)
ItemEvent
1107(1)
ItemListener Interface
1108(1)
JButton
1108(1)
JCheckBox
1108(1)
JComboBox
1109(1)
JComponent
1110(1)
JFrame
1111(1)
JLabel
1112(1)
JList
1113(1)
JOptionPane
1114(1)
JPasswordField
1114(1)
JRadioButton
1115(1)
JTextArea
1116(1)
JTextField
1117(1)
ListSelectionListener Interface
1118(1)
Math
1118(1)
MouseEvent
1119(1)
MouseListener Interface
1119(1)
MouseMotionListener Interface
1120(1)
NumberFormat
1120(1)
ObjectInputStream
1121(1)
ObjectOutputStream
1121(1)
PrintWriter
1122(1)
Scanner
1123(2)
String
1125(1)
StringTokenizer
1126(1)
System
1127(2)
Appendix G Solutions to Selected Exercises
1129(20)
Index 1149

An electronic version of this book is available through VitalSource.

This book is viewable on PC, Mac, iPhone, iPad, iPod Touch, and most smartphones.

By purchasing, you will be able to view this book online, as well as download it, for the chosen number of days.

Digital License

You are licensing a digital product for a set duration. Durations are set forth in the product description, with "Lifetime" typically meaning five (5) years of online access and permanent download to a supported device. All licenses are non-transferable.

More details can be found here.

A downloadable version of this book is available through the eCampus Reader or compatible Adobe readers.

Applications are available on iOS, Android, PC, Mac, and Windows Mobile platforms.

Please view the compatibility matrix prior to purchase.