The Fundamentals of Programming
This chapter introduces beginners to programming and its applications. Using a variety of examples, it explains data types, variables, functions (methods), conditionals, and more. It serves as a foundation for Chapter 2, in which readers begin to write real Java code.
All of the code listings in Chapter 1 are short example snippets that will not compile and run on an actual machine. No source code is available for this chapter. There is a minor error in one of the examples that is shown here.
This section will be updated as needed. Please post on our forums if you need assistance or explanation on topics covered in this chapter.
1. More on Semicolons: Learn about when the semicolon is needed and when it is not.