Function to calculate an average
Hello,
I am trying to write a function to calculate an average.
I have a range from which I choose a formula:
math english sport formula
30% 30% 40% 1
20% 40% 40% 2
and another range with grades:
math english sport formula total_grade
50 60 80 1
60 80 90 2
How can I write a function which will calculate total grade upon formula
value
(use formula according to the value in the second range) ?
Thank you
David D.
|