Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Using C++ programming. Storing Matrices in 2-Dimensional Arrays. MODIFY A SECTION OF THE GIVEN MATRIX This assignment is about working with two-dimensional arrays in a

Using C++ programming. Storing Matrices in 2-Dimensional Arrays. image text in transcribed
MODIFY A SECTION OF THE GIVEN MATRIX This assignment is about working with two-dimensional arrays in a C++ programming environment. You are given a 7X7 square matrix (see the screenshots for the input matrix) and asked to develop a C++ program to modify a section of the given matrix by adding an integer number to all values in a selected part of the matrix (a sub-matrix selected by the user). REQUIREMENTS (See screen shot on last page) Model the user interface as shown in the screen shot. You should set the distance between the columns within the matrix display on the screen using setw() . First of all, your program will display the given matrix on the screen. This is to confirm that the given matrix was built properly (your starting point). . Next, ask the user to enter the integer number to be added to the sub-matrix that they will select. Do not allow the user to enter a floating point number. . Finally, ask the user to enter the beginning row and column offset and the ending row and column offset to define the sub-matrix that they wish to modify. For example, if the user enters (0, 0) as the beginning offset and (6, 6) as the ending offset, they will select the entire matrix to receive the modification. . After receiving all five user input parameters, your program will update the matrix by adding the integer value that the user has given to each element in the sub-matrix. . Display the final matrix after the modification is applied. Provide information for programmers about the program sections by placing comments within the program at the beginning of each of the three sections (matrix display, modifications, matrix redisplay). . NOTES NOTE 1: Array values are shown in the screen shot and should be hard-coded into your program. Do not use an input data file. NOTE 2: Remember to use zero-based offsets to reference array positions. NOTE 3: Follow the instructions strictly and do not add additional cases into the program. Using advanced features of C++ is not permitted, and your assignment may be rejected for grading, which will result in a grade of zero. NOTE 4: You must provide complete and accurate program file header. NOTE 5: You MUST follow the required naming format for your source code and functions. Do NOT name your source code file "main.cpp" NOTE 6: The user interface (which appears on the black console screen) must have same format as in the provided screen shot. NOTE 7: Test your program rigorously to make sure that it performs correctly for a variety of situations. The instructor is not going to test it for you. Once you submit the assignment, there are no do-overs. Please make sure your program works correctly. A program that produces severely flawed output will be graded down considerably, not because the program is flawed, but because you did not test it adequately to detect serious and obvious problems! NOTE 8: You may clear the screen with system("CLS") if needed. er to the chanter Exercises posted in Blackboard for an example of using a 2

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

The Manga Guide To Databases

Authors: Mana Takahashi, Shoko Azuma, Co Ltd Trend

1st Edition

1593271905, 978-1593271909

More Books

Students also viewed these Databases questions