So this code is not  yet completed. The end result has to calculate the average grade by each question. A=1 b=2 etc... and checks if the question is passed or not. this is what I got this far. #include <stdio.h>#define ROW 6#define COLOMN 5int input[ROW][COLOMN] , row, column;int main(void){float passedtests , returnedtests , percentage = (passedtest/returnedtest*100);char filepath[100]=  ;//----- openen van extern bestand door middel van input van user.FILE *inputfile;printf(\n);printf(enter path of file.\n);scanf(%s, &filepathpath);inputfile=fopen(filepath, r );    if (inputfile == NULL){ printf(file not found.); }fscanf(inputfile, %f, &passedtests);fscanf(inputfile, %f, &returnedtests);    for (row=0; row<ROW; row++)       {           for (colomn=0; column<COLUMN ; colomn++)           {                   fscanf(inputfile, %d, &input[row][colomn]);           }       }printf(passed tests: %0.f\n , passedtests);printf(Returned tests: %0.f\n , returnedtests);printf(Response is: %.1f %% \n\n , percentage);printf(   \t A\t B \t C \t D \t E \t grade \t comment\n\n);for (row=0; row<ROW; row++) {if (colomn==(COLOMN-1)) {printf(question %d   ,row+1);}            if (colomn==COLOMN) {printf(\n);}                for (colomn=0; colomn<COLOMN ; colomn++)                {                    printf(%d  , input[row][colomn]);                } }}The output has to be like something like this: number of passed tests: 20Number of returned tests: 19Response is 95%.            A      B      C      D   E   grade     passedquestion 1  2      2      2      2   2    2.4       yesquestion 2  2      2      2      2   2    2.4       yesquestion 3  2      2      2      2   2    2.4       yesquestion 4  2      2      2      2   2    2.4       yesquestion 5  2      2      2      2   2    2.4       yesquestion 6  2      2      2      2   2    2.4       yesSo how far Am I ? I have made everything until calculating the average. Anyone got a good idea on how to do this ? Also I think the response variable is not good. Please check it out thank you !btw the guys @ stackoverflow said to post code review here. THE input file is like this: 201912457018738542022411023356004123
Reads data from file. calculates on percentage and shows a table
c
There are too many coding style issues here, that make this really hard to read.Inconsistent indentation throughoutToo tightly packed expressions, for example:Instead of for (row=0; row<ROW; row++)This is easier to read: for (row = 0; row < ROW; row++)Code within {...} without line breaks, for example:Instead of if (column==(COLUMN-1)) {printf(vraag %d   ,row+1);}This is easier to read:if (column == COLUMN - 1) {    printf(vraag %d  , row + 1);}When you have two if conditions that will never be both true at the same time like this:if (column == COLUMN - 1) ...if (column == COLUMN) ...That really should be written with an else if:if (column == COLUMN - 1) ...else if (column == COLUMN) ...You opened a file with fopen,but didn't close.It's recommended to clean up any file handles opened by your program,close them before you exit.inputbestand=fopen(bestandpad, r );//------ Boolean operator. Controle op geldigheid invoer.if (inputbestand == NULL){ printf(Bestand niet gevonden.); }//--inscannen eerste twee variablen,fscanf(inputbestand, %f, &uitgereikt);First of all,the comment doesn't make any sense.There's no boolean operator anywhere here.But the bigger problem is that if opening the file fails,the program simply continues execution as if nothing happened,trying to read from a NULL file handle...Instead of printf(\n);, I recommend puts();.It's shorter, simpler, faster.