C programminghow would i create a function that reads the


C PROGRAMMING:

how would I create a function that reads the contents of a file and inputs the contents into the main program...for example: 

instead of 

int item[5] = {1200,3000,4000,3333,2222}

to something like

int item[5] = FUNCTIONNAME

and the function would contain the fopen and fscanf functions...

Solution Preview :

Prepared by a verified Expert
Basic Computer Science: C programminghow would i create a function that reads the
Reference No:- TGS01371248

Now Priced at $10 (50% Discount)

Recommended (96%)

Rated (4.8/5)