Top News

calculate area of circle

 

public class Area_of_circle
{
    public static void main(String[] args)
    {
       int r=5;
       double pi=3.14;
       double area=pi*r*r;
       System.out.println("Area of circle is : "+area);
    
    }
}


Output: Area of circle is : 78.5

Post a Comment

Previous Post Next Post