Write a Java program using variables to find the area and Perimeter of a square of side 6 cm [Area= side * side Perimeter = 4*side]
Answers
Answered by
0
This article is created to cover a program in Java that calculates area and perimeter of a square based on the length of its side entered by user at run-time of the program.
Note - The area of a square is calculated using the formula s*s or s2. Where s is the length of side.
Note - The perimeter of a square is calculated using the formula 4*s.
Similar questions