CREATE TABLE student (stuid DECIMAL, lname TEXT, fname TEXT, age DECIMAL, sex TEXT, major DECIMAL, advisor DECIMAL, city_code TEXT)
CREATE TABLE voting_record (stuid DECIMAL, registration_date TEXT, election_cycle TEXT, president_vote DECIMAL, vice_president_vote DECIMAL, secretary_vote DECIMAL, treasurer_vote DECIMAL, class_president_vote DECIMAL, class_senator_vote DECIMAL)

Find the distinct last names of the students who have class president votes.
SELECT DISTINCT T1.lname FROM student AS T1 JOIN voting_record AS T2 ON T1.stuid = T2.class_president_vote
SELECT DISTINCT "T1"."lname" FROM "student" AS "T1" JOIN "voting_record" AS "T2" ON "T1"."stuid" = "T2"."class_president_vote"