Question: n this lab exercise, you are required to write a C + + program to add two 4 * * 5 matrices and then output
n this lab exercise, you are required to write a program to add two matrices and then output the res
Prompt the user to enter the name of two files with matrices
Compute the sum of the two matrices and output the results
A sample run is as follows:
Please enter the name of the file containing data for Array : inputtxt
Please enter the name of the file containing data for Array : inputtxt
The sum is:
Further requirements:
Create three functions:
readArray with void return and one array argument and one string argument
printArray with void return and one D array argument
sumArray with void return and three D array arguments
Separate your code into three files as described in the lab:
main.cpp
myFunction.cpp
myFunction.
Remember, you will have to break the compiling into three steps now:
ac main.cpp
b c myFunction. cpp
c g main.o myfunction. o o main
The two input files are available by clicking: inputtxt and inputtxt
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
