Question: 6 Chrome File Edit View History Bookmarks Profiles Tab Window Help . 92%1:lI sun7234 PM . . nu. Week One Assignment - CSC X mL

 6 Chrome File Edit View History Bookmarks Profiles Tab Window Help

6 Chrome File Edit View History Bookmarks Profiles Tab Window Help . 92%1:lI sun7234 PM . . nu. Week One Assignment - CSC X mL Week One Assignment - CSC X V Week Assignment 1_ v3.pdf X + Update Apple ID Settings H a . Some account services will not be 0 n nationalutbrightspacetcom available until you sign in again' I WeekAssignment1_v3.pdf 120% + El 03 P3 An Array of objects (15 points) In this problem we will continue to expand on problem 2. 3. Write the function with the header void printCube (RectangularCube rc) that receives an object of the type RectangularCube and displays the length, width, height, volume and the surface area of the cube like: L = 2, W = 1, H = 1, V = 2, A = 8. This function should be implemented as a nonmember function, meaning that it should be dened outside the class RectangularCube [3pts]. Write a main function in which you declare an array of 5 RectangularCube objects [2pts]. Inside the main function, use a loop to initialize/populate this array of RectangularCube. In the body of the loop use the rand () function to generate random integers between 1 and 10 to assign to length, width and height data fields of each RectangularCube object [Spts]. After populating the array, use another loop to display individual elements of the array in part (a) by calling the function printCube in part (a) [3pts]t Code submission and sample output [2pts]. Your CH code for this problem - Copy and paste your code here Run the code and insert the result in the following box. Copy and paste the result here (e.g. the screenshot of the result you get by running the code)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!