Reference variable : Variable « JSP « Java Tutorial






<%--
  Copyright (c) 2002 by Phil Hanna
  All rights reserved.
  
  You may study, use, modify, and distribute this
  software for any purpose provided that this
  copyright notice appears in all copies.
  
  This software is provided without warranty
  either expressed or implied.
--%>
<%@ page session="false" %>
<%
   int value = 3;
%>
<P>The value is <%= value %></p>
<%
   value += 2;
%>
<P>After adding 2, the value is <%= value %></p>








23.2.Variable
23.2.1.Creating a Variable
23.2.2.Define variable and reference it later
23.2.3.Reference variable
23.2.4.Page counter