Example 5 1
//pag 48 http://www.greenteapress.com/thinkapjava/thinkapjava.pdf
 
public class example_5_1    
{
 
    public static double area(double radius) {
        return Math.PI*radius*radius;
    }
 
    public static void main(String [] args) {
        //code
        double a = 3.3;
        System.out.println(area(a));
    }
}

voltar

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-Share Alike 2.5 License.