Using Operators : Operator « JSP « Java






Using Operators

<HTML>
  <HEAD>
    <TITLE>Using Operators</TITLE>
  </HEAD>

  <BODY>
    <H1>Using Operators</H1>
    <%
        int operand1 = 23, operand2 = 4, product;

        product = operand1 * operand2;

        out.println(operand1 + " * " + operand2 +
            " = " + product);
     %>
  </BODY>
</HTML>

           
       








Related examples in the same category

1.Adding value
2.Checking Operator Precedence
3.Using Logical Operators
4.Using Relational Operators
5.Addition and Subtraction
6.Multiplication and Division
7.Incrementing and Decrementing