题解 | #考试分数(四)#

考试分数(四)

https://www.nowcoder.com/practice/502fb6e2b1ad4e56aa2e0dd90c6edf3c

with a as (select *
                , rank() over (partition by job order by score) r
           from grade)
select job
     , floor((count(r) + 1) / 2) as 'start'
     , floor((count(r) + 2) / 2) as 'end'
from a
group by job
order by job;

#窗口函数#
全部评论

相关推荐

03-13 10:35
安徽大学 Java
牛客246100688号:蚂蚁卡简历的,简历看不上眼全a了也不会有面试的。
投递蚂蚁集团等公司9个岗位
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客企业服务