119k views
3 votes
The length of a rectangle is stored in a double variable named length, the width in one named width. write an expression whose value is the length of the diagonal of the rectangle. submit

1 Answer

4 votes
sqrt(pow(length, 2) + pow(width, 2))

User Masnun
by
8.0k points