Meta interview question

some sql question dealing with join func