text: Calculate area of a cyclic quadrilateral with given side lengths | Function to find the area of cyclic quadrilateral ; Stores the value of half of the perimeter ; Stores area of cyclic quadrilateral ; Return the resultant area ; Driver Code
code: function calculateArea ( A , B , C , D ) { let S = ( A + B + C + D ) / 2 let area = Math . sqrt ( ( S - A ) * ( S - B ) * ( S - C ) * ( S - D ) ) return area ; } let A = 10 ; let B = 15 ; let C = 20 ; let D = 25 ; document . write ( calculateArea ( A , B , C , D ) . toFixed ( 3 ) )