## Program to find the area and perimeter of the semicircleIn this article, we will discuss the program to find the area and perimeter of semicircle in different programming languages. But before writing the programs, let's first see a brief description of the semicircle and the formulae to find its area and perimeter. ## SemicircleWhen a line passes through the center and touches the two ends of the circle, then a semicircle is formed. The diameter of a circle divides it into two halves that are referred to as semicircles. A semicircle is the half part of a circle. ## Area of semicircleThe area of semicircle is equal to half of the area of a circle. When we divide the area of a circle by 2, we will get the area of the semicircle. The area of a circle is πr Area of semicircle =1/2( πr The perimeter of a semicircle is equivalent to the sum of diameter and half of the circumference of a circle. The formula for perimeter of the circle can be Now, let's see the programs to find the area and perimeter of the semicircle. ## Programs to find the area and perimeter of the semicircleIn the programs, we are using the formulae given below -
After the execution of the above code, and after entering the value of the radius, the output will be -
After the execution of the above code, the output will be - After entering the value and clicking on OK, the output will be -
So, that's all about the article. Here, we have discussed the programs to find the area and perimeter of semicircle in C, C++, Java, C#, PHP, python, and JavaScript. Hope you find the article helpful and informative. Next TopicPrograms List |