Introduction to Java

Data Types II: boolean

Fantastic! You just printed an int data type.

The next data type we will use is the boolean.

  1. A boolean is a data type that can only be either true or false.
Community Forums
Get help and ask questions in the Codecademy Forums
Report a Bug
If you see a bug or any other issue with this page, please report it here.