Set the name in cell a 1 and enter in g2:
=IF(COUNTIF(C2:F2," & gt0”)= 4,SUM(C2:F2),IF(COUNTIF(C2:F2,0)=4,0,(C2/0. 1+D2/0.2+E2/0.3+F2/0.4)/(4-COUNTIF(C2:F2,0)))
Then drop it down and fill it.
Functional analysis:
Judge whether the scores of the four exams of this subject are all greater than 0. If so, add up the scores of the four tests. Otherwise, it is judged whether all the four exams are 0, and if so, 0 is returned; Otherwise, return the sum of the original scores of the four exams, divided by the number of times that are not zero. Get a comprehensive score.