+ Start a Discussion
Hari nadh babu Eluru 7Hari nadh babu Eluru 7 

diagonal length of rectangle

write the apex class to define diagonal length of rectangle formula to substitute values formula is
diagonal length of rectangle formula
Best Answer chosen by Hari nadh babu Eluru 7
Suraj Tripathi 47Suraj Tripathi 47
Hi Hari nadh babu Eluru 7,

Try this:
public class diagonal_Length {
    public static void find_diagonalLength(integer length,integer width ){
        decimal diagonalLength;
        diagonalLength= Math.sqrt(((length*length) +(width*width)));
    }
}

I hope you find the above solution helpful. If it does, please mark it as Best Answer to help others too.

Thanks and Regards,
Suraj Tripathi

All Answers

Suraj Tripathi 47Suraj Tripathi 47
Hi Hari nadh babu Eluru 7,

Try this:
public class diagonal_Length {
    public static void find_diagonalLength(integer length,integer width ){
        decimal diagonalLength;
        diagonalLength= Math.sqrt(((length*length) +(width*width)));
    }
}

I hope you find the above solution helpful. If it does, please mark it as Best Answer to help others too.

Thanks and Regards,
Suraj Tripathi
This was selected as the best answer
Hari nadh babu Eluru 7Hari nadh babu Eluru 7
how to see output for this code sir