solution

C Program

I want to write a c program that will read a binary file. Every file stores a two dimensional array of integers stored as bytes. For ex. a file named “16_16” has 16 rows and 16 columns. The program should take three arguments from the command line, filename, rows, columns.

If file 4_4 contained,

[ [0 2 4 6]

[8 10 12 14]

[16 18 20 22]

[24 26 28 30]]

a program with the parameters, 4_4,2,2 would show

[ [0 2]

[8 10]]

I want the program to store the retrieved subarray in a separate array.

It should also check if the file exists or not and notify the user if an argument is missing.

Please comment if you have a question.

 
"Looking for a Similar Assignment? Get Expert Help at an Amazing Discount!"
Looking for a Similar Assignment? Our Experts can help. Use the coupon code SAVE30 to get your first order at 30% off!