Java:Introduction to Problem Solving and Programming with MyProgrammingLab: International Edition
Pearson Education Limited
978-0-273-76028-3 (ISBN)
- Titel erscheint in neuer Auflage
- Artikel merken
Chapter 1 Introduction to Computers and Java 1
1.1 Computer Basics 2
Hardware and Memory 3
Programs 6
Programming Languages, Compilers, and Interpreters 7
Java Bytecode 9
Class Loader 11
1.2 A Sip of Java 12
History of the Java Language 12
Applications and Applets 13
A First Java Application Program 14
Writing, Compiling, and Running a Java Program 19
1.3 Programming Basics 21
Object-Oriented Programming 21
Algorithms 25
Testing and Debugging 27
Software Reuse 28
1.4 Graphics Supplement 30
A Sample Graphics Applet 30
Size and Position of Figures 32
Drawing Ovals and Circles 34
Drawing Arcs 35
Running an Applet 37
Chapter 2 Basic Computation 47
2.1 Variables and Expressions 48
Variables 49
Data Types 51
Java Identifiers 53
Assignment Statements 55
Simple Input 58
Simple Screen Output 60
Constants 60
Named Constants 62
Assignment Compatibilities 63
Type Casting 65
Arithmetic Operators 68
Parentheses and Precedence Rules 71
Specialized Assignment Operators 72
Case Study: Vending Machine Change 74
Increment and Decrement Operators 79
More About the Increment and Decrement Operators 80
2.2 The Class String 81
String Constants and Variables 81
Concatenation of Strings 82
String Methods 83
String Processing 85
Escape Characters 88
The Unicode Character Set 89
2.3 Keyboard and Screen I/O 91
Screen Output 91
Keyboard Input 94
Other Input Delimiters (Optional) 99
Formatted Output with printf (Optional) 101
2.4 Documentation and Style 103
Meaningful Variable Names 103
Comments 104
Indentation 107
Using Named Constants 107
2.5 Graphics Supplement 109
Style Rules Applied to a Graphics Applet 110
Creating a Java GUI Application with the JFrame Class 110
Introducing the Class JOptionPane 113
Reading Input as Other Numeric Types 123
Programming Example: Change-Making Program
with Windowing I/O 124
Chapter 3 Flow of Control: Branching 137
3.1 The if-else Statement 138
The Basic if-else Statement 139
Boolean Expressions 145
Comparing Strings 150
Nested if-else Statements 155
Multibranch if-else Statements 157
Programming Example: Assigning Letter Grades 159
Case Study: Body Mass Index 162
The Conditional Operator (Optional) 165
The exit Method 165
3.2 The Type boolean 166
Boolean Variables 167
Precedence Rules 168
Input and Output of Boolean Values 171
3.3 The switch Statement 173
Enumerations 179
3.4 Graphics Supplement 180
Specifying a Drawing Color 181
A Dialog Box for a Yes-or-No Question 184
Chapter 4 Flow of Control: Loops 195
4.1 Java Loop Statements 196
The while Statement 197
The do-while Statement 200
Programming Example: Bug Infestation 205
Programming Example: Nested Loops 211
The for Statement 213
Declaring Variables within a for Statement 219
Using a Comma in a for Statement (Optional) 220
The for-each Statement 222
4.2 Programming with Loops 222
The Loop Body 223
Initializing Statements 224
Controlling the Number of Loop Iterations 225
Case Study: Using a Boolean Variable to End a Loop 227
Programming Example: Spending Spree 229
The break Statement and continue Statement in Loops
(Optional) 232
Loop Bugs 235
Tracing Variables 237
Assertion Checks 239
4.3 Graphics Supplement 241
Programming Example: A Multiface Applet 241
The drawstring Method 247
Chapter 5 Defining Classes and Methods 261
5.1 Class and Method Definitions 263
Class Files and Separate Compilation 265
Programming Example: Implementing a Dog Class 265
Instance Variables 266
Methods 269
Defining void Methods 272
Defining Met
Erscheint lt. Verlag | 11.8.2011 |
---|---|
Verlagsort | Harlow |
Sprache | englisch |
Maße | 188 x 232 mm |
Gewicht | 1541 g |
Themenwelt | Schulbuch / Wörterbuch |
Informatik ► Programmiersprachen / -werkzeuge ► Java | |
Informatik ► Software Entwicklung ► Objektorientierung | |
ISBN-10 | 0-273-76028-9 / 0273760289 |
ISBN-13 | 978-0-273-76028-3 / 9780273760283 |
Zustand | Neuware |
Haben Sie eine Frage zum Produkt? |
aus dem Bereich