Learn

Congratulations! You’ve learned some of the building blocks of Java programming. What can we generalize so far?

  • Data Types are int, boolean, and char.
  • Variables are used to store values.
  • Whitespace helps make code easy to read for you and others.
  • Comments describe code and its purpose.
  • Arithmetic Operators include +, -, *, /, and %.
  • Relational Operators include <, <=, >, and >=.
  • Equality Operators include == and !=.

A full understanding of these concepts is key to understanding the remainder of the Java course. Let’s keep going!

Instructions

1.

Write a single line comment anywhere you want. It can be anything! (Make sure it starts with //)

2.

Set the boolean variable isComplete to true.

3.

Set the int variable awesomeLevel equal to 121.

4.

Set the int variable epicLevel equal to awesomeLevel multiplied by 2.

5.

Uncomment the last line so that the console prints out the value of epicLevel.

Take this course for free

Mini Info Outline Icon
By signing up for Codecademy, you agree to Codecademy's Terms of Service & Privacy Policy.

Or sign up using:

Already have an account?