Computer Science, asked by shree102, 11 months ago

plzz answer it Java programming


If u dont know the answer then plzz dont answer it If u will answer that I dont know then go to hell .There are many Slangs and Curse for u .......................... If u know the answer then u can answer it
I know I am talking in rude way coz I always get answer that ''I dont know"
sorry \: for \: being \: rude

Attachments:

Answers

Answered by anishasa
0

Answer:

Area of Square = a^{2}

Area of Circle = \pi * r^{2}

Program:

public class Java

{

public static void main(String[] args)

{

  int a=4;

  int s;

  float r= (float) 3.2;

  a=a*a;

  System.out.println("Area of square = "+a);

  s=(int) (Math.PI*r*r);

  System.out.println("Area of Circle = "+s);

  if(a>s)

  {

      System.out.println("Area of Square is greater");

  }

  else

  {

      System.out.println("Area of Circle is greater");

  }

   }

}

OUTPUT:

Area of square = 16

Area of Circle = 32

Area of Circle is greater

Similar questions