Click here to navigate the course.

Drag the edges to resize the window.

In Projects, you can keep track of your progress as you go throught the tasks. Check each item as you complete it!

Code Editor
Learn

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.

  1. A variable stores a value.

  2. 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;

The variable myLuckyNumber now stores the value 7 as an int type.

A semicolon ; 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.

Report a Bug
If you see a bug or any other issue with this page, please report it here.