Exercise 5 (25 Marks)
Write a program called Sums.m which reads a text file consisting of a matrix ofcomma separated numbers, appends the sum (i.e., add the summation of allelements at the end) to each row and each column and rewrites the (tabulated)numbers back to another file. It should be possible for the user to select the nameof this new file when the program is running. If the input file is as follows (create atext file using Notepad and put the numbers below on it and save it):3.4,27,53,1.2
6.3,7.9,52,04
7.1,8.0,23,4.9
Then the output produced should be:
3.400000, 2.700000, 5.300000, 1.200000, 12.600000
6.300000, 7.900000, 5.200000, 0.400000, 19.800000
7.100000, 8.000000, 2.300000, 4.900000, 22.300000
16.800000, 18.600000, 12.800000, 6.500000

Found something interesting ?

• On-time delivery guarantee
• PhD-level professional writers
• Free Plagiarism Report

• 100% money-back guarantee
• Absolute Privacy & Confidentiality
• High Quality custom-written papers

Related Model Questions

Feel free to peruse our college and university model questions. If any our our assignment tasks interests you, click to place your order. Every paper is written by our professional essay writers from scratch to avoid plagiarism. We guarantee highest quality of work besides delivering your paper on time.

Grab your Discount!

25% Coupon Code: SAVE25
get 25% !!