tailieunhanh - How to program java

Introduction to Computers, the Internet and the Web Introduction What Is a Computer? Computer Organization Evolution of Operating Systems Personal, Distributed and Client/Server Computing Machine Languages, Assembly Languages and High-Level Languages History of C++ History of Java Java Class Libraries Other High-Level Languages Structured Programming The Internet and the World Wide Web Basics of a Typical Java Environment General Notes about Java and This Book Thinking About Objects: Introduction to Object Technology and the Unified Modeling Language Discovering Design Patterns: Introduction Tour of the Book (Optional). | Contents Preface xxxv 1 Introduction to Computers the Internet and the Web 1 Introduction 2 What Is a Computer 7 Computer Organization 7 Evolution of Operating Systems 8 Personal Distributed and Client Server Computing 9 Machine Languages Assembly Languages and High-Level Languages 10 History of C 11 History of Java 12 Java Class Libraries 13 Other High-Level Languages 14 Structured Programming 14 The Internet and the World Wide Web 15 Basics of a Typical Java Environment 16 General Notes about Java and This Book 19 Thinking About Objects Introduction to Object Technology and the Unified Modeling Language 22 Discovering Design Patterns Introduction 26 Tour of the Book 28 Optional A Tour of the Case Study on Object-Oriented Design with the UML 41 Optional A Tour of the Discovering Design Patterns Sections 45 2 Introduction to Java Applications 55 Introduction 56 A First Program in Java Printing a Line of Text 56 Compiling and Executing your First Java Application 61 Copyright 2002 by Prentice Hall. All Rights Reserved. VIII Contents Modifying Our First Java Program 62 Displaying a Single Line of Text with Multiple Statements 62 Displaying Multiple Lines of Text with a Single Statement 63 Displaying Text in a Dialog Box 65 Another Java Application Adding Integers 69 Memory Concepts 75 Arithmetic 76 Decision Making Equality and Relational Operators 79 Optional Case Study Thinking About Objects Examining the Problem Statement 87 3 Introduction to Java Applets 105 Introduction 106 Sample Applets from the Java 2 Software Development Kit 107 The TicTacToe Applet 107 The DrawTest Applet 111 The Java2D Applet 112 A Simple Java Applet Drawing a String 112 Compiling and Executing WelcomeApplet 118 Two More Simple Applets Drawing Strings and Lines 120 Another Java Applet Adding Floating-Point .