Program to calculate area and perimeter of equilateral triangle | Python3 program to calculate Area and Perimeter of equilateral Triangle ; Function to calculate Area of equilateral triangle ; Function to calculate Perimeter of equilateral triangle ; Driver code
from math import * NEW_LINE def area_equilateral ( side ) : NEW_LINE INDENT area = ( sqrt ( 3 ) / 4 ) * side * side NEW_LINE print ( " Area ▁ of ▁ Equilateral ▁ Triangle : ▁ % ▁ f " % area ) NEW_LINE DEDENT def perimeter ( side ) : NEW_LINE INDENT perimeter = 3 * side NEW_LINE print ( " Perimeter ▁ of ▁ Equilateral ▁ Triangle : ▁ % ▁ f " % perimeter ) NEW_LINE DEDENT side = 4 NEW_LINE area_equilateral ( side ) NEW_LINE perimeter ( side ) NEW_LINE