1 Write a C++ program to calculate a rectangle's area. The program consists of the following function: • getLength This function should ask the user to enter the rectangle's length, and then returns...


1<br>Write a C++ program to calculate a rectangle's area. The program consists of the<br>following function:<br>• getLength This function should ask the user to enter the rectangle's length,<br>and then returns that value as a double<br>• getWidth - This function should ask the user to enter the rectangle's width,<br>and then returns that value as a double.<br>getArea – This function should accept the rectangle's length and width as<br>arguments and return the rectangle's area.<br>• displayData – This function should accept the rectangle's length, width and<br>area as arguments, and display them in an appropriate message on the<br>screen.<br>main – This function consists of calls to the above functions.<br>

Extracted text: 1 Write a C++ program to calculate a rectangle's area. The program consists of the following function: • getLength This function should ask the user to enter the rectangle's length, and then returns that value as a double • getWidth - This function should ask the user to enter the rectangle's width, and then returns that value as a double. getArea – This function should accept the rectangle's length and width as arguments and return the rectangle's area. • displayData – This function should accept the rectangle's length, width and area as arguments, and display them in an appropriate message on the screen. main – This function consists of calls to the above functions.

Jun 04, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here