Okay! Let's think simply about this and set up an equation.
18 votes + 22 votes + y votes = ?
It has to equal 68 votes because the problem says everyone voted.
All we need to do to figure out how much y is, is to subtract 18 and 22 from 68.
That way, we are left with however many votes the student gave to the 3rd candidate.
18 + 22 + y = 68
y = 68 - 18 - 22
y = 28
Your answer is 28 votes