I am pretty sure this is easy to solve and I am a bit embarrassed to post it but I dont quite get it (tried a tree diagram but it doesnt work for me or I might do it wrong?!):

Of a class of 100 students 80 attend lectures. The whole class is made to sit a multiple choice test. On the first question, any student who has attended lectures knows the answer. The other students each know the answer with probability 0.5. Any student who knows the answer gets it right; a student who does not know, picks an answer at random from the three choices offered. The teacher selects a student who has answered the first question correctly. Show that the probability that my student attended lectures is 6/7.

Please help! Ive been stuck on it for ages. Thank you already!!!