Alphabetical List of Syntax Boxes

Similar documents
Computing Concepts with Java Essentials

Java (12 Weeks) Introduction to Java Programming Language

Fundamentals of Java Programming

core. Volume I - Fundamentals Seventh Edition Sun Microsystems Press A Prentice Hall Title ULB Darmstadt

Java Application Developer Certificate Program Competencies

Java 6 'th. Concepts INTERNATIONAL STUDENT VERSION. edition

PROBLEM SOLVING SEVENTH EDITION WALTER SAVITCH UNIVERSITY OF CALIFORNIA, SAN DIEGO CONTRIBUTOR KENRICK MOCK UNIVERSITY OF ALASKA, ANCHORAGE PEARSON

AP Computer Science Java Subset

CS 111 Classes I 1. Software Organization View to this point:

Formal Engineering for Industrial Software Development

RARITAN VALLEY COMMUNITY COLLEGE ACADEMIC COURSE OUTLINE. CISY 105 Foundations of Computer Science

Java the UML Way: Integrating Object-Oriented Design and Programming

Basic Programming and PC Skills: Basic Programming and PC Skills:

Java SE 8 Programming

The Sun Certified Associate for the Java Platform, Standard Edition, Exam Version 1.0

ARIZONA CTE CAREER PREPARATION STANDARDS & MEASUREMENT CRITERIA SOFTWARE DEVELOPMENT,

Facebook Twitter YouTube Google Plus Website

Computer Programming I

Introduction to Programming System Design. CSCI 455x (4 Units)

Charles Dierbach. Wiley

Specialized Programme on Web Application Development using Open Source Tools

AP Computer Science A - Syllabus Overview of AP Computer Science A Computer Facilities

Java Interview Questions and Answers

Programming and Software Development (PSD)

KITES TECHNOLOGY COURSE MODULE (C, C++, DS)

Computer Programming I & II*

Syllabus for CS 134 Java Programming

Course Number: IAC-SOFT-WDAD Web Design and Application Development

Thomas Jefferson High School for Science and Technology Program of Studies Foundations of Computer Science. Unit of Study / Textbook Correlation

Specialized Programme on Web Application Development using Open Source Tools

PART-A Questions. 2. How does an enumerated statement differ from a typedef statement?

The C Programming Language course syllabus associate level

Java 7 Recipes. Freddy Guime. vk» (,\['«** g!p#« Carl Dea. Josh Juneau. John O'Conner

Designing with Exceptions. CSE219, Computer Science III Stony Brook University

Glossary of Object Oriented Terms

CompuScholar, Inc. Alignment to Utah's Computer Programming II Standards

Topics. Parts of a Java Program. Topics (2) CS 146. Introduction To Computers And Java Chapter Objectives To understand:

Programming and Software Development CTAG Alignments

El Dorado Union High School District Educational Services

TECHNOLOGY Computer Programming II Grade: 9-12 Standard 2: Technology and Society Interaction

Professional. SlickEdif. John Hurst IC..T...L. i 1 8 О 7» \ WILEY \ Wiley Publishing, Inc.

Java Programming Language

Programming Language Pragmatics

JAVA - QUICK GUIDE. Java SE is freely available from the link Download Java. So you download a version based on your operating system.

ML for the Working Programmer

: provid.ir

The first program: Little Crab

Windows PowerShell Essentials

Object-Oriented Design Lecture 4 CSU 370 Fall 2007 (Pucella) Tuesday, Sep 18, 2007

Domains and Competencies

Curriculum Map. Discipline: Computer Science Course: C++

2 The first program: Little Crab

Moving from CS 61A Scheme to CS 61B Java

VB.NET Programming Fundamentals

D06 PROGRAMMING with JAVA

Summit Public Schools Summit, New Jersey Grade Level / Content Area: Mathematics Length of Course: 1 Academic Year Curriculum: AP Computer Science A

Java Software Structures

FLORIDA STATE COLLEGE AT JACKSONVILLE COLLEGE CREDIT COURSE OUTLINE. Introduction to Programming with Visual Basic.NET

DIPLOMADO DE JAVA - OCA

Pemrograman Dasar. Basic Elements Of Java

First Java Programs. V. Paúl Pauca. CSC 111D Fall, Department of Computer Science Wake Forest University. Introduction to Computer Science

#820 Computer Programming 1A

An Introduction to Object-Oriented Programming with

ARIZONA CTE CAREER PREPARATION STANDARDS & MEASUREMENT CRITERIA SOFTWARE DEVELOPMENT,

Topics. Introduction. Java History CS 146. Introduction to Programming and Algorithms Module 1. Module Objectives

Name: Class: Date: 9. The compiler ignores all comments they are there strictly for the convenience of anyone reading the program.

JAVA IN A NUTSHELL O'REILLY. David Flanagan. Fifth Edition. Beijing Cambridge Farnham Köln Sebastopol Tokyo

Visual Basic. murach's TRAINING & REFERENCE

JavaScript: Control Statements I

Introduction to Java Applications Pearson Education, Inc. All rights reserved.

C++ Programming Language

Copyright. Restricted Rights Legend. Trademarks or Service Marks. Copyright 2003 BEA Systems, Inc. All Rights Reserved.

ALLIED PAPER : DISCRETE MATHEMATICS (for B.Sc. Computer Technology & B.Sc. Multimedia and Web Technology)

MULTIPLE CHOICE. Choose the one alternative that best completes the statement or answers the question.

CS 141: Introduction to (Java) Programming: Exam 1 Jenny Orr Willamette University Fall 2013

AP Computer Science Java Mr. Clausen Program 9A, 9B

AppendixA1A1. Java Language Coding Guidelines. A1.1 Introduction


Objectif. Participant. Prérequis. Remarque. Programme. C# 3.0 Programming in the.net Framework. 1. Introduction to the.

Computer Programming I

Fundamentals of Programming and Software Development Lesson Objectives

TYLER JUNIOR COLLEGE School of Continuing Studies 1530 SSW Loop 323 Tyler, TX

Chapter 13 - Inheritance

UIL Computer Science for Dummies by Jake Warren and works from Mr. Fleming

Java Programming Fundamentals

DATA STRUCTURES USING C

I PUC - Computer Science. Practical s Syllabus. Contents

University of Twente. A simulation of the Java Virtual Machine using graph grammars

Chapter 1: Key Concepts of Programming and Software Engineering

Embedded Systems. Review of ANSI C Topics. A Review of ANSI C and Considerations for Embedded C Programming. Basic features of C

Chapter 1 Java Program Design and Development

Programming Using Python

DE 6211 DISTANCE EDUCATION. M.Sc. (IT) DEGREE EXAMINATION, MAY PRINCIPLES OF INFORMATION TECHNOLOGY. (2002 onwards) PART A (10 3 = 30 marks)

Android Application Development Course Program

BELEN JESUIT PREPARATORY SCHOOL Computer Science Department COURSE DESCRIPTIONS. And OBJECTIVES

Multichoice Quetions 1. Atributes a. are listed in the second part of the class box b. its time is preceded by a colon. c. its default value is

ADVANCED SCHOOL OF SYSTEMS AND DATA STUDIES (ASSDAS) PROGRAM: CTech in Computer Science

Programming Languages CIS 443

Programming in C# with Microsoft Visual Studio 2010

Comp 411 Principles of Programming Languages Lecture 34 Semantics of OO Languages. Corky Cartwright Swarat Chaudhuri November 30, 20111

Transcription:

Special Features xvii Alphabetical List of Syntax Boxes Array Construction 282 Array Element Access 283 Assertion 337 Assignment 37 Block Statement 193 Calling a Superclass Constructor 481 Calling a Superclass Method 479 Cast 106 Class Definition 73 Constant Definition 112 Constructor Definition 72 Defining a Generic Class 846 Defining a Generic Method 853 Defining an Enumerated Type 213 Defining an Interface 414 Exception Specification 557 finally Clause 562 General try Block 559 Implementing an Interface 414 Importing a Class from a Package 48 Inheritance 471 Inner Classes 425 Instance Field Declaration 78 Instantiating a Generic Class 843 Method Call 21 Method Definition 71 Object Construction 45 Package Specification 352 Static Method Call 124 The for each Loop 293 The for Statement 241 The if Statement 192 The instanceof Operator 484 The return Statement 81 The while Statement 236 Throwing an Exception 555 Variable Definition 35

xviii Table of Special Features Chapter Common Errors How Tos Quality Tips 1 Introduction Omitting Semicolons 22 Misspelling Words 24 2 Using Objects Trying to Invoke a Constructor Like a Method 46 3 Implementing Classes Forgetting to Initialize Object References in a Constructor 90 Trying to Call a Method Without an Implicit Parameter 93 Designing and Implementing a Class 85 4 Fundamental Data Types Integer Division 121 Unbalanced Parentheses 122 Roundoff Errors 125 Carrying Out Computations 125 Do Not Use Magic Numbers 115 Choose Descriptive Variable Names 115 White Space 122 Factor Out Common Code 123 5 Programming Graphics (Optional) Drawing Graphical Shapes 170 Calculate Sample Data Manually 183 6 Decisions Using == to Compare Strings 198 The Dangling else Problem 210 Multiple Relational Operators 216 Confusing && and Conditions 217 7 Iteration Infinite Loops 236 Off-by-One Errors 237 Forgetting a Semicolon 246 A Semicolon Too Many 246 Brace Layout 193 Avoid Conditions with Side Effects 201 Prepare Test Cases Ahead of Time 211 Implementing Loops 254 Use for Loops for Their Intended Purpose 245 Don t Use!= to Test the End of a Range 247 Symmetric and Asymmetric Bounds256 Count Iterations 256

Table of Special Features xix Productivity Hints Advanced Topics Random Facts Understand the File System 15 Have a Backup Strategy 16 Alternative Comment Syntax 20 The ENIAC and the Dawn of Computing 7 Don t Memorize Use Online Help 52 Testing Classes in an Interactive Environment 49 Mainframes When Dinosaurs Ruled the Earth 55 The javadoc Utility 76 Using the Command Line Effectively 88 Calling One Constructor from Another 93 Electronic Voting Machines 94 Avoid Unstable Layout 117 Reading Exception Reports 130 Big Numbers 107 Binary Numbers 107 Combining Assignment and Arithmetic 118 Escape Sequences 131 Strings and the char Type 132 Formatting Numbers 137 Reading Input from a Dialog Box 139 The Pentium Floating-Point Bug 109 International Alphabets 133 Applets 158 The Evolution of the Internet 160 Computer Graphics 174 Indentation and Tabs 194 Keyboard Shortcuts for Mouse Operations 203 Copy and Paste in the Editor 204 Make a Schedule and Make Time for Unexpected Problems 212 The Selection Operator 195 The switch Statement 205 Enumerated Types 212 Lazy Evaluation of Boolean Operators 217 De Morgan s Law 218 Artificial Intelligence 219 do Loops 238 Scope of Variables Defined in a for Loop Header 247 The Loop and a Half Problem 257 The break and continue Statements 258 Loop Invariants 265 Spaghetti Code 239 Correctness Proofs 267

xx Table of Special Features Chapter Common Errors How Tos Quality Tips 8 Arrays and Array Lists Bounds Errors 283 Uninitialized Arrays 284 Length and Size 289 Underestimating the Size of a Data Set 307 Working with Array Lists and Arrays 301 Prefer Parameterized Array Lists 289 Make Parallel Arrays into Arrays of Objects 307 9 Designing Classes Trying to Modify Primitive Type Parameters 331 Shadowing 349 Confusing Dots 356 Programming with Packages 356 Consistency 328 Minimize Side Effects 333 Don t Change the Contents of Parameter Variables 333 10 Testing and Debugging Debugging 398 11 Interfaces and Polymorphism 12 Event Handling (Optional) Forgetting to Define Implementing Methods as Public 415 Trying to Instantiate an Interface 418 Modifying the Signature in the Implementing Method 430 Forgetting to Attach a Listener 450 Forgetting to Repaint 459 Implementing a Graphical User Interface (GUI) 453 13 Inheritance Confusing Super- and Subclasses 472 Shadowing Instance Fields 479 Failing to Invoke the Superclass Method 480 Accidental Package Access 493 Making Inherited Methods Less Accessible 493 Defining the equals Method with the Wrong Parameter Type 500 Forgetting to Clone 502 Clone Mutable Instance Fields in Accessor Methods 502

Table of Special Features xxi Productivity Hints Advanced Topics Random Facts Global Search and Replace 350 Regular Expressions 350 Array Initialization 284 Two-Dimensional Arrays with Variable Row Lengths 302 Multidimensional Arrays 302 Partially Filled Arrays 308 Methods with a Variable Number of Parameters 309 Call by Value and Call by Reference 334 Class Invariants 339 Alternative Forms of Field Initialization 345 Static Imports 351 An Early Internet Worm 310 The Explosive Growth of Personal Computers 358 Batch Files and Shell Scripts 385 Reading Test Inputs from a File 379 Unit Testing with JUnit 386 Constants in Interfaces 416 Anonymous Classes 426 The First Bug 399 The Therac-25 Incidents 400 Operating Systems 433 Don t Use a Container as a Listener 450 Code Reuse 454 Event Adapters 459 Programming Languages 460 Supply tostring in All Classes 497 Abstract Classes 490 Final Methods and Classes 491 Protected Access 494 Inheritance and the tostring Method 497 Inheritance and the equals Method 500 Implementing the clone Method 503 Enumerated Types Revisited 505 Scripting Languages 506

xxii Table of Special Features Chapter Common Errors How Tos Quality Tips 14 Graphical User Interfaces (Optional) Layout Management 528 15 Exception Handling Throw Early, Catch Late 560 Do Not Squelch Exceptions 560 Do Not Use catch and finally in the Same try Statement 562 Do Throw Specific Exceptions 564 16 Files and Streams Backslashes in File Names 578 Negative byte Values 582 Using Files and Streams 597 17 Object-Oriented Design CRC Cards and UML Diagrams 619 18 Recursion Infinite Recursion 668 Tracing Through Recursive Methods 672 Thinking Recursively 673 19 Sorting and Searching The compareto Method Can Return Any Integer, Not Just 1, 0, and 1 732 20 An Introduction to Data Structures 21 Advanced Data Structures Forgetting to Define hashcode 795 Choosing a Container 813 Use Interface References to Manipulate Data Structures 780 22 Generic Programming Genericity and Inheritance 854 Writing Code That Does Not Work After Types Are Erased 857 Using Generic Types in a Static Context 858

Table of Special Features xxiii Productivity Hints Advanced Topics Random Facts Adding the main Method to the Frame Class 517 Visual Programming 544 The Ariane Rocket Incident 569 Use Object Streams 599 File Dialog Boxes 578 Command Line Arguments 579 Serializing Geometric Objects 599 Attributes and Methods in UML Diagrams 620 Multiplicities 621 Aggregation and Association 621 Encryption Algorithms 586 Programmer Productivity 613 Software Development Art or Science? 655 The Limits of Computation 684 Insertion Sort 713 Oh, Omega, and Theta 715 The Quicksort Algorithm 722 The Parameterized Comparable Interface 733 The Comparator Interface 733 The Iterable Interface and the For Each Loop 746 Static Inner Classes 758 The First Programmer 724 Standardization 765 Reverse Polish Notation 810 Software Piracy 814 Wildcard Types 855