wap a java program please it is important
Attachments:
Answers
Answered by
0
Answer:
dor86e96dp7sosoydoyd
Answered by
0
import java.util.*;
public class Square
{
public static void main(String args[])
{
Scanner in = new Scanner(System.in);
System.out.println("enter the side of the square");
double side = in.nextDouble();
double area = side * side ;
double diagonal = Math.sqrt(2) * side ;
System.out.println("area of square = "+area);
System.out.println("Diagonal of square = "+diagonal);
}
}
Similar questions
Science,
2 months ago
Computer Science,
4 months ago
Physics,
4 months ago
Science,
10 months ago
Math,
10 months ago