Casting to a New Type : Data Type « JSP « Java Tutorial






<HTML>
  <HEAD>
    <TITLE>Casting to a New Type</TITLE>
  </HEAD>

  <BODY>
    <H1>Casting to a New Type</H1>
    <%
        float float1;
        double double1 = 1;

        float1 = (float) double1;

        out.println("float1 = " + float1);
     %>
  </BODY>
</HTML>








23.3.Data Type
23.3.1.An Automatic Data Conversion
23.3.2.Casting to a New Type
23.3.3.Format Date
23.3.4.Date format