Learn Object-Oriented Java the Hard Way

Really learn object-oriented Java step-by-step

“Learn Object-Oriented Java the Hard Way” is a book that teaches you the object-oriented parts of Java with over 50 complete example programs that illustrate each concept step-by-step.

Each concept is demonstrated with working code and explained, so that you understand what every line of code does and why it is there. After you work through this book, you should be able to understand the basic structure and function of any Java program, even large programs by professional developers.

The exercises and explanations in this book are distilled from my over fifteen years of experience teaching object-oriented programming to everyday students.

Your book will be available as a download in PDF, Kindle (.mobi) and iPad (.epub) versions so you can read it on all of your favorite devices.

Get Started

The Book
  • 309-page book in PDF, Kindle and iPad formats. Really learn the object-oriented features of Java, even if other books have failed you.
  • Java source code for all the example programs in the book
  • dozens of Study Drills (one or more per chapter) to test your understanding

There are no tutorial videos yet; I'll be recording those over the next few months.

Sample Book

If you're still undecided, you should read the first twelve chapters for free on this site or I can email you a sample book containing just the free chapters.

What You Will Learn

“Learn Object-Oriented Java the Hard Way” focuses on the object-oriented parts of Java and covers them deeply, with plenty of complete working examples and the explanations you won’t find in other books.

You need some experience in Java or a similar language before you will be able to make it through this material. If you have never programmed before in any language, you should start with my intro book “Learn Java the Hard Way”. But if you already know the basics of Java or another language like C, C++, C# or Javascript, this book is for you. And if you only know a very different language like Python or Ruby then you will have some catching up to do but will probably still be fine.

In the final chapter you’ll write a graphical version of a popular checker-dropping game and know how to package it up in a JAR file to send to others. You will learn:

  • How to install the Java compiler and a text editor
  • How to work with Java objects and create your own classes
  • Fields and instance variables
  • Methods and Parameters
  • Constructors
  • Reference Variables vs Primitives
  • Generics and Casting
  • Inheritance
  • Interfaces
  • Abstract Classes and Methods
  • Packages
  • How to create JAR files
  • Graphical User Interfaces in JavaFX
  • Mouse and Keyboard Input in GUIs
  • Testing and Efficiency
  • Algorithmic Complexity and Big-O Notation
  • ArrayLists
  • Sorting

...and more!

About the Author

Teaching regular people to code since 1997.

2016 photo of the author -- Graham Mitchell
Hi, I'm Graham Mitchell!

I have been teaching Computer Science at Leander High School (near Austin, TX) since the fall of 1997. We are a pretty good school; consistently ranked near the top 5% of public schools nationally.

Most authors of “how to code” text books have never worked in the classroom or have only taught university students who are already majoring in Computer Science or who have quite a bit of prior experience. And although I have had a lot of exceptional students over the years, most of my students are regular kids with zero experience and no particular aptitude for programming.

I taught them to code, and I can teach you.

You should follow me on Twitter.

Frequently-Asked Questions

» What is included in the book?
The book is a DRM-free PDF. You can also download Kindle (.mobi) and iPad (.epub) versions if those are more your style. The book contains 55 exercises that walk you through creating programs and explaining what each line does. All the tools you need to create Java programs are included or freely available. Also included is a zip file containing all the source code and text files used in the book.
» Does this book have tutorial videos like your other book?
Not yet, unfortunately. I wanted to get the book out there and I'll be recording the videos over the next few months. If you buy the book I will email you once videos are available.
» Are you affiliated with Zed Shaw, who wrote the excellent book Learn Python the Hard Way?
No, but I have spoken to him on the phone. He knows about this project and has given it his blessing.
» Can I email you to get help?
Sure. Email graham@grahammitchell.com and I will do what I can.

“Learn Object-Oriented Java the Hard Way” is ©2015– Graham Mitchell