Maximum area of rectangle inscribed in an equilateral triangle | CPP implementation to find the maximum area inscribed in an equilateral triangle ; Function to find the maximum area of the rectangle inscribed in an equilateral triangle of side S ; Maximum area of the rectangle inscribed in an equilateral triangle of side S ; Driver Code
#include <bits/stdc++.h> NEW_LINE using namespace std ; double solve ( int s ) { double area = ( 1.732 * pow ( s , 2 ) ) / 8 ; return area ; } int main ( ) { int n = 14 ; cout << solve ( n ) ; }