Data types in Java

Summary

This chapter will go through the so called basic / primitive data types in Java. In programs, data is stored in variables where each variable corresponds to a memory location in the computer. Because variables can be used over and over again, they become very useful and form the basis of programming.

We will see how we can declare (create) different variables and constants, and also the differences between different data types. We will also see how we can use the variables and what opportunities and limitations they result in.