请教!!
java bean程序为:package test;
public class Circle{
int radius;
public Circle(){
radius =1;
}
public int getradius(){
return radius;
}
public void setradius(int newradius){
radius=newradius;
}
public double carea(){
return 3.14159*radius*radius;
}
public double clength(){
return 2.0*3.14159*radius;
}
}
jsp程序为:
<%@ page language="java" import="java.util.*" pageEncoding="gb2312"%>
<html>
<head>
<title>My JSP '1.jsp' starting page</title>
</head>
<jsp:usebean id="first" scope="application" class="test.Circle"/>
<body>
<%first.setradius(10)%>
<h3>圆的半径:<%=first.getradius() %></h3>
<h3>圆的面积:<%=first.carea()%></h3>
<h3>圆的周长<%=first.clength() %></h3>
</body>
</html>
运行时中提示<%first.setradius(10)%>出错。怎么修改啊!