Find the diagonal of the Cube | CPP program to find length of the diagonal of the cube ; Function to find length of diagonal of cube ; Formula to Find length of diagonal of cube ; Driver code ; Function call
#include <bits/stdc++.h> NEW_LINE using namespace std ; float diagonal_length ( float a ) { float L ; L = a * sqrt ( 3 ) ; return L ; } int main ( ) { float a = 5 ; cout << diagonal_length ( a ) ; return 0 ; }