Area of the biggest possible rhombus that can be inscribed in a rectangle | Java Program to find the biggest rhombus which can be inscribed within the rectangle ; Function to find the area of the biggest rhombus ; the length and breadth cannot be negative ; area of the rhombus ; Driver code
import java . io . * ; class GFG { static float rhombusarea ( float l , float b ) { if ( l < 0 b < 0 ) return - 1 ; return ( l * b ) / 2 ; } public static void main ( String [ ] args ) { float l = 16 , b = 6 ; System . out . println ( rhombusarea ( l , b ) ) ; } }