Java Program || Write a Java program to enter radius of a circle and find its diameter, circumference and area.||
JAVA PROGRAM Write a Java program to enter radius of a circle and find its diameter, circumference and area. Solution :- (Hint) diameter = 2 * radius, circumference = 2 * 3.14 * radius area = 3.14 * radius * radius Static :- class circle { public static void main(String args[]) { int radius = 10; double pi = 3.14; double diameter,circumference,area; diameter = 2 *radius; circumference = 2 * pi * radius; area = pi * radius * radius; System.out.println("The diameter of the circle :-"+diameter); System.out.println("The circumference of the circle :-"+circumference); System.out.println("The area of the circle"+area); } } Output :- Dynamic :- import java.util.*; class circle { public static void main(String args[]) { Scanner in = new Scanner(System.in); System.out.println("Enter the radius :- &q