SELECT
    AVG(moyenne)
FROM (
    SELECT
        ETU.Nom,
        ETU.Prenom,
        SUM(MAT.CoeffMat * AVG(EVA.Note)) / SUM(MAT.CoeffMat) AS moyenne
    FROM
        ETUDIANT AS ETU
    INNER JOIN
        EVALUER AS EVA ON EVA.NumEtudiant = ETU.NumEtudiant
    INNER JOIN
        MATIERE AS MAT ON MAT.CodeMat = EVA.CodeMat
    GROUP BY
        ETU.Nom,
        ETU.Prenom
) AS SousRequete;
