题解 | 统计每个用户的平均刷题数
select university,difficult_level, count(qpd.question_id)/count(distinct qpd.device_id) as avg_answer_cnt from question_practice_detail as qpd left join user_profile as up on qpd.device_id=up.device_id left join question_detail as qd on qd.question_id=qpd.question_id group by university,difficult_level having up.university='山东大学'