Our goal in this chapter is to convince you that writing a computer program is easier than writing a piece of text such as a paragraph or an essay. In this chapter, we take you through these building blocks, get you started on programming in Java, and study a variety of interesting programs.
Our textbook Introduction to Programming in Java [Amazon · Addison-Wesley] is an interdisciplinary approach to the traditional CS1 curriculum. We teach all of the classic elements of programming, using an "objects-in-the-middle" approach that emphasizes data abstraction. A key feature of the book is the manner in which we motivate each programming concept by examining its impact on specific applications, taken from fields ranging from materials science to genomics to astrophysics to internet commerce. The book is organized around four stages of learning to program: