Skip Top Navigation Bar

Experiment with Arithmetic Basics

In this activity, you will make predictions regarding the outcome of given expressions. You will use the Java Playground to test your predictions.

Grab a Piece of Paper, Predict and Try!

  1. Create a table on a piece of paper. Include a column for each expression, your prediction, the actual value, and your explanation.
  2. Take some time to predict the value of each arithmetic expression.
  3. Once you have recorded all your predictions, run the code in the Java Playground and record the value in the actual value column.
  4. For any expression where your prediction and the actual value differs, write an explanation of how the expression is evaluated.
  5. Need Help? Check Out This Tutorial

What does each arithmetic Operator do?

For each operator, write a description of what it does and provide your own example.

  1. +
  2. -
  3. *
  4. /
  5. %
  6. ( )