I am working on a project for school in which you must take an answer key, students names and their answers from a text file and output how many the students got right. I have the grade key and all the students answers in different arrays, i am having trouble making a loop to compare the arrays and add 1 for every correct answer. Also it is suppose to be ordered in a void function but i'm not even worried about that until I figure out this loop. Any help would be great, thanks.
for//a for loop because you are preforming an action for each element in a set ( form 0 to 6 )
(int i = 0;//start at 0
i < 7;//7 elements total. if this condition is false, the loop ends.
i++){//in every loop go one step forward..
if(Akey[i] == n1A[i]) s1++;//what you did
}