Let’s add the percentages up.
There were twelve people who had an average of 80. With this, you just have to believe they all received an 80%. The same with the score of 86.
12•80=960
18•86=1,548
Now add them together.
960+1,548=2,508
Now add the total students.
12+18=30
2,508/30
83.6
The class average is 83.6%