I do not wish to do your homework for you but i will give you a start :}
Look at my problem i posted. that works fine for taking in a numeric value and adding it to another value. you want to create additional variables called 'total' and 'scores entered' or something like that and rather than set the value to form element like i am doing in my function, you want to add the value to total every time the fuction is called (maybe you have 2 buttons, one is enter test score, and another is grade)
so you collect all your test scores and click grade which calls a grade function that looks at total/scores enterd to give the average and converts it to a letter grade (use if statements)
that should be a good start. try something, post some code and i will help you more.