Dr. Pais' AP Computer Science Course: WJ Textbook & JBuilder Project Files
Java
Au Naturel
A computer science
textbook by Dr. William C. Jones, Jr.
Fourth Edition, Copyright May 26, 2004, www.javabook.org
Over 100 high school and
college instructors across the U.S.A. and around the world are teaching from
this (free !) textbook.
Chapter 0. Contents and Preface
Table of Contents and Preface to Student (pdf file) 10
pages
Note: In Dr. Pais’ course we
will be using Borland’s free JBuilder Foundation as our IDE (Integrated
Development Environment). Once you have Java and JBuilder installed on your
computer, you should be able to launch everything you need from the links below
on this webpage. JBuilder Projects have been set up in advance for all the
programs and exercises we will use in the textbook.
Chapter 1.
Chapter 1 Textbook (pdf file) Objects 34
pages Chapter 1 All program listings (html
file)
Overview, objects, classes, subclasses, methods, defining and using void
instance methods for objects that draw pictures.
JBuilder
Chapter 1 Programs
JBuilder
Chapter 1 Exercises
Chapter 2.
Chapter 2 Textbook (pdf file) Conditionals
and Boolean Methods 36 pages Chapter 2 All
program listings (html file)
Defining and using boolean instance methods, if-else statements, boolean
operators, UML (Unified Modeling Language).
JBuilder
Chapter 2 Programs
JBuilder
Chapter 2 Exercises
Chapter 3.
Chapter 3 Textbook (pdf file) Loops
and Parameters 32 pages Chapter 3 All
program listings (html file)
While statements, loops, parameters, more on analysis and design, more UML.
JBuilder
Chapter 3 Programs. Note that the programs that we will concentrate on most are
the ones located in the left column below, which are not in the book.
JBuilder
Chapter 3 Exercises. Note that these exercises are not in the book and that the
instructions for each one are contained in the file itself.
Interlude: Integers and
For-loops 6 pages included with Chapter Four
Chapter 4 Instance Variables
42 pages listings
JOptionPane for I/O. defining instance
variables and constructors. polymorphism. BlueJ.
New: Simplified event-handling.
Chapter 5 Class Methods and Class
Variables 34 pages listings
defining and using class members. final
variables. scope. networks and recursion (optional).
Review: Overall Java Language So Far 6 pages included at
the end of Chapter Five
Chapter 6 Basic Data Types and
Expressions 43 pages listings
doubles, Strings, chars, longs. Math. MVC
pattern.
Chapter 7 Arrays 41
pages listings
array algorithms. sequential search.
insertion sort. basic 2-dimensional arrays.
Chapter 8 Elementary Graphics
40 pages listings
applets. Graphics2D and the Shape classes.
extended analysis and design.
New: Turtle is a subclass of Turtlet, which can be used for
applets.
Chapter 9 Exception-Handling
38 pages listings
runtime exceptions. try/catch. checked
exceptions. additional Java statements.
Chapter 10 Event-Driven Programming
44 pages listings
frames and components. textfields and
buttons. more MVC. sliders, timers, menus, mice.
Chapter 11 Abstract Classes and
Interfaces 40 pages listings
interfaces. instanceof. polymorphism. Double,
Integer, and other wrappers.
Chapter 12 Files and Multidimensional
Arrays 36 pages listings
FileReader and FileWriter. StringTokenizer.
RandomAccessFile. bytecode.
Chapter 13 Sorting and Searching
32 pages listings
selection sort, insertion sort, big-oh,
binary search, quicksort, mergesort, shellsort.
Chapter 14 Stacks and Queues
42 pages listings
implementing stacks and queues with arrays
and linked lists (header and trailer nodes).
Chapter 15 Collections and Linked
Lists 40 pages listings
implementing Collection, Iterator, and
ListIterator with arrays and linked lists. doubly-linked lists.
Chapter 16 Maps and Linked Lists
42 pages listings
implementing Map and Iterator with arrays and
linked lists. Scheme interpreter. hash tables.
Chapter 17 Binary Trees
42 pages listings
implementing Map and Iterator with binary
trees. red-black and AVL trees. data flow diagrams.
Chapter 18 Priority Queues, Heaps, and
More Sorting 38 pages listings
implementing priority queues with arrays and
linked lists. treesort, heapsort, external sorting.
Chapter 19 Graphs 38
pages listings
list and matrix implementations. Prim's,
Kruskal's, Dijkstra's algorithms. dynamic programming.
Chapter 20 Models of Computation
36 pages listings
finite automata, pushdown automata, Turing Machines,
and solvability. context-free LL(1).
Appendices 54 pages
listings
Appendix A Guidelines for Program Style
APP-1
Appendix B Glossary of Terms
APP-5
Appendix C Common Compile-Time Errors
APP-17
Appendix D Java Reserved Words
APP-22
Appendix E Sun Library Classes
APP-23
Appendix F Major Programming Projects
APP-29
Dr. Bradley Kjell has very helpful webpages providing additional practice with Java, although they are not coordinated with this book. The object-oriented webpages can be covered much earlier than his numbering indicates.
My course syllabi using this book can be linked to from this main page.