Think Java, 2nd Edition
by Allen Downey and Chris Mayfield
Think Java is an excellent introduction to computer science and programming intended for people with little or no experience. We start with the most basic concepts and are careful to define all terms when they are first used. The book presents each new idea in a logical progression. Larger topics, like recursion and object-oriented programming, are divided into smaller examples and introduced over the course of several chapters.
This revised and expanded second edition, currently under development, contains many improvements and additions to the first edition, which remains available here.
- Chapter 1: Computer programming
- Chapter 2: Variables and Operators
- Chapter 3: Input and Output
- Chapter 4: Methods and Testing
- Chapter 5: Conditionals and Logic
- Chapter 6: Loops and Strings
- Chapter 7: Arrays and References
- Chapter 8: Recursive Methods
- Chapter 9: Immutable Objects
- Chapter 10: Mutable Objects
- Chapter 11: Designing Classes
- Chapter 12: Arrays of Objects
- Chapter 13: Objects of Arrays
- Chapter 14: Extending Classes
- Appendix A: Tools
- Appendix B: Javadoc
- Appendix C: Graphics
- Appendix D: Debugging
- Appendix E: Extras
- The Authors' Website contains more information about the book and provides a downloadable PDF.