题解 | #统计每个学校各难度的用户平均刷题数#

统计每个学校各难度的用户平均刷题数

https://www.nowcoder.com/practice/5400df085a034f88b2e17941ab338ee8

select
  university,
  difficult_level,
  sum(date) / count(university)
from
  user_profile a,
  (
    select
      device_id,
      count(b.question_id) date,
      difficult_level
    from
      question_detail a,
      question_practice_detail b
    where
      a.question_id = b.question_id
    group by
      device_id,
      difficult_level
  ) b
where
  a.device_id = b.device_id
group by
  university,
  b.difficult_level
order by
  university;
全部评论

相关推荐

牛客ID:561366855:期望薪资多少?难以相信这简历找不到工作。说明二本电子信息专业想对口就业非常难。
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客企业服务