The int, boolean, and char are fundamental data types of Java that we will see again later in the course.
Another important feature of Java (and of many programming languages) is the ability to store values using variables.
A variable stores a value.
In Java, all variables must have a specified data type.
We can assign a variable to a specified data type, like this:
int myLuckyNumber = 7;
myLuckyNumber now stores the value
7 as an
; is also used to end all Java single code statements. We will cover statements that should not end in a semicolon later in this course.